I'm having trouble making the user input line with what I'm typing. Is anyone able to find a way to fix my code? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

I'm having trouble making the user input line with what I'm typing. Is anyone able to find a way to fix my code?

https://code.sololearn.com/cUyP39eSbNxt/?ref=app

29th Sep 2019, 12:13 AM
SweetHoneyMcGee
SweetHoneyMcGee - avatar
4 Answers
+ 1
The code works fine. Just notice You are asking age first. After that you are asking for the name 23 Alice Works fine to drink a beer with Alice
30th Sep 2019, 7:31 PM
sneeze
sneeze - avatar
+ 1
If you want to enter age and compare it with integer in if statement You first need to convert you age which is in string type to integer type. Because this cause error because it can't use operand between string and int.
29th Sep 2019, 3:04 AM
Chirag Kumar
Chirag Kumar - avatar
+ 1
I'm trying to get yourAge to equal Age but I get errors regardless of what I try
30th Sep 2019, 7:25 PM
SweetHoneyMcGee
SweetHoneyMcGee - avatar
0
You are using Console.ReadLine twice for YourAge. The second time over writes the first time. https://code.sololearn.com/cmYq3CnSIjIO
30th Sep 2019, 7:18 PM
sneeze
sneeze - avatar