From: Tanushree Bhoi Date: 2006-06-15T22:06:38+09:00 Subject: Re: A very basic question. ------=_Part_74331_1279325.1150376794059 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Thanks Joey for your reply. But when i am writting like this in my ruby irb. scanf("%d %s") its not responding.For require 'scanf' its giving 'true'. I am using ruby 184-16. Thanks Tanushree On 6/15/06, Joey wrote: > > irb> > irb(main):001:0> require 'scanf' > => true > irb(main):004:0> scanf("%d %s") > 1 lemon > => [1, "lemon"] > > On 6/15/06, Tanushree Bhoi wrote: > > > > Thanks Dick. > > > > On 6/15/06, Dick Davies wrote: > > > > > > On 15/06/06, Tanushree Bhoi wrote: > > > > > > > What is the syntax(function) for taking user input(numbers not > strings > > ) > > > in > > > > ruby. > > > > > > gets() returns Strings because that's how console i/o works, > > > but you can convert that to an number with String#to_i . > > > > > > > > > -- > > > Rasputin :: Jack of All Trades - Master of Nuns > > > http://number9.hellooperator.net/ > > > > > > > > > > > > -- > >> > > ------=_Part_74331_1279325.1150376794059--