0
How to correctly take an input from the user? Please write a code how to take a string input and int input. Thank you very much!
2 ответов
+ 1
Use Console.ReadLine(); Which will be used to get the string i/p from user.
To get int input, use the same command and covert the string to int. For eg.
int num = Convert.ToInt32(Console.ReadLine());
Please note that there mightbe some syntax issue. Hope it will be helpful to you
0
It depends on your program type: console app, win forms, etc