+ 2

Help me with Console.ReadLine()

If you write: string Age = Console.ReadLine(); string Name = Console.ReadLine(); Console.WriteLine(Age + Name); It just ask only first string (Age) How to fix it?

11th Nov 2024, 10:36 AM
Tapper Games
Tapper Games - avatar
3 ответов
+ 2
The SoloLearn code editor requires you to provide all input in the input box before the program starts. When you run your program, answer both questions: 15 Tommy Then hit the button. It will work fine. Just everything has be put in up front.
11th Nov 2024, 1:33 PM
Jerry Hobby
Jerry Hobby - avatar
+ 1
I fix it. Just in app one Console.ReadLine don't show new asking box and you need to go on another line.
11th Nov 2024, 11:20 AM
Tapper Games
Tapper Games - avatar
0
Then, how to clear two tests in challenges, if i can't create two output boxes?
11th Nov 2024, 1:35 PM
Tapper Games
Tapper Games - avatar