- 1

Practice 5.2 C++

What I am doing bad? using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Code_Coach_Challenge { class Program { static void Main(string[] args) { string name = Console.ReadLine(); Console.WriteLine("Name: ", name); int age = Convert.ToInt32(Console.ReadLine()); Console.WriteLine("You are {0} years old", age); } } }

19th Mar 2021, 4:30 PM
Sven G.D.
Sven G.D. - avatar
2 Respuestas
+ 5
string name = Console.ReadLine(); int age = Convert.ToInt32(Console.ReadLine()); Console.WriteLine("Name: "+ name); Console.WriteLine("Age: "+ age); Something like this No need to write "You are {0} years old" N.B C# not C++ 😁
19th Mar 2021, 4:46 PM
!Derrickee
!Derrickee - avatar
+ 4
Omg thank you! I am totally a nOOb as you can see...
19th Mar 2021, 5:00 PM
Sven G.D.
Sven G.D. - avatar