Directly read integer from Console

Dec 6 2004 1:31 AM
Console.Readline() returns string. After that we have to convert it to integer etc for our requirment. is the following possible: 1. We can directly receive input in the form of integer without explicit conversion from string to integer 2. Is it possible that any console method can read only characters. e.g. we want to enter Y or N. in that case Console.Readline() will return string, though it solves the purpose. Is there any character reading function

Answers (1)