Displaying 2 results from an estimated 2 matches for "backwardslash".
2012 Mar 23
7
gsub
hi,
im getting tired on this one.
i want to replace all forwardslashes with backwardslashes.
irb:
r = "C:/RAILS/"
r.gsub("/", "\\") or r.gsub("/") {(''\''} both give me:
"C:\\RAILS\\"
how can i use gsub to display only one "\"?
regards
--
You received this message because you are subscribed to the Google Gr...
2009 Dec 13
2
how to replace a single backward slash with a double backward slash?
Dear R-helpers:
Hours ago, I asked how to replace a single forward slash with a double
backward slash and recieved great help. Thanks again for all the repliers.
In the meantime, I wonder how to replace a single backward slash with a
double backward slash?
e.g., I want change "c:\test" into "c:\\test"
I tried the following but does not work.