From: Brian Wisti Date: 2004-09-17T06:40:04+09:00 Subject: Re: Ex-Perl coders: Howz it feel to convert to Ruby? --- Nate Smith wrote: > Try > > print "a" + 1 > > Won't work -- you have to do > > print "a" + 1.to_s > > > Nate That "+" means you're building a new string from two Strings. Since the second operand is not a String, the conversion has to be explicit. Now, for simple printing, it just occurred to me to test what happens when you hand a printf-style expression to print, as I might do in the same situation with Python: irb > print "a%d" % 1 a1 => nil So, that's One Way To Do It. -- Brian Wisti http://coolnamehere.com/