M
mpthimios
Hi,
I am trying to format some text using sprintf. The text itself
contains the percent sign (%).
When I use it without any escape character, as expected ruby throws
error (unkonown format sequence).
When I use the "\%" sequence ruby complaints when the "\%" is
somewhere in the text. When it is at the end it works but I don't want
it there.
When I use the "%%" sequence, I get the exact sequence as output ("%%"
is printed!!).. \
Has anyone observed this behavior? Am I doing something wrong or it is
a ruby bug?
Thanks in advance,
Efthimios.
I am trying to format some text using sprintf. The text itself
contains the percent sign (%).
When I use it without any escape character, as expected ruby throws
error (unkonown format sequence).
When I use the "\%" sequence ruby complaints when the "\%" is
somewhere in the text. When it is at the end it works but I don't want
it there.
When I use the "%%" sequence, I get the exact sequence as output ("%%"
is printed!!).. \
Has anyone observed this behavior? Am I doing something wrong or it is
a ruby bug?
Thanks in advance,
Efthimios.