Peter Hickman wrote in post #1038899: > When you do the mark = get() what you actually get back is a string > and not a number. You cant compare a string to a number so the if(mark > < 50) fails. You need top convert the string into a number. You should > do this > > if(mark.to_i < 50) > > this will convert the string into an integer (if it can). Thanks a lot Mr.Hickman understood the basic casting. -- Posted via http://www.ruby-forum.com/.