Hiya All,
Continuing on learning the basics of Ruby I've stumbled on a common
issue I can't seem to resolve. Searched and made some progress but not
quite cracked it.
I have a line in my code that is:
puts "The current sale price is #{163.chr}#{rand(10)*2},000 - cash only
please."
I'm looking to have the pound symbol shown (£) but it comes out as an
accented u (ú). I understood that Ruby was using 8859-1 table
(http://en.wikipedia.org/wiki/ISO/IEC_8859-1).
However, in testing out various characters I see anything above 126
doesn't appear as expected.
So to ask the question; how can I get the £ symbol (and perhaps others)
to print out?
I'm running Win 7, testing through a CMD window, with Ruby 1.9.2
Full code at - http://codepad.org/Tq9zLBm3
Thanks in advance!
D
···
--
Posted via http://www.ruby-forum.com/.