Thanks Moritz, it worked :)
In reply to Re^2: How do I read just one line of input by prasaduco in thread How do I read just one line of input by prasaduco