Im doing some manipulation of strings, and there are some characters
that Ruby just really does not like:
“ –
If you try to paste these into a Ruby console the cursor will jump
around. Likewise, if you put it in a string and try to do text[5,4] it
will give you the wrong piece of the text.
How do I get around this. Is there some special escape command or do I
just have to gsub these characters?
With the information at hand it might be an encoding issue,
what version are you using, please paste the output of ruby -v
R.
···
On Tue, Apr 21, 2009 at 9:41 PM, Aryk Grosz <tennisbum2002@hotmail.com> wrote:
Im doing some manipulation of strings, and there are some characters
that Ruby just really does not like:
“ –
If you try to paste these into a Ruby console the cursor will jump
around. Likewise, if you put it in a string and try to do text[5,4] it
will give you the wrong piece of the text.
Im doing some manipulation of strings, and there are some characters
that Ruby just really does not like:
“ –
If you try to paste these into a Ruby console the cursor will jump
around. Likewise, if you put it in a string and try to do text[5,4] it
will give you the wrong piece of the text.
How do I get around this. Is there some special escape command or do I
just have to gsub these characters?
Perhaps you could try a real programming language?
You'll probably need to adjust your terminal settings to accept these characters.
···
On Apr 21, 2009, at 12:41, Aryk Grosz wrote:
Im doing some manipulation of strings, and there are some characters
that Ruby just really does not like:
“ –
If you try to paste these into a Ruby console the cursor will jump
around. Likewise, if you put it in a string and try to do text[5,4] it
will give you the wrong piece of the text.
How do I get around this. Is there some special escape command or do I
just have to gsub these characters?
Adam do not pay attention, Pascal is convinced that CL is a real
programming language. (1)
Never mind, he is a nice guy, just suffering from parenoia.
R.
(1) He is not the only one.
···
On Tue, Apr 21, 2009 at 10:55 PM, Pascal J. Bourguignon <pjb@informatimago.com> wrote:
Perhaps you could try a real programming language?
--
Si tu veux construire un bateau ...
Ne rassemble pas des hommes pour aller chercher du bois, préparer des
outils, répartir les tâches, alléger le travail… mais enseigne aux
gens la nostalgie de l’infini de la mer.
If you want to build a ship, don’t herd people together to collect
wood and don’t assign them tasks and work, but rather teach them to
long for the endless immensity of the sea.