Noob here error: no overload for method ReadLine

hi im new to c# and ive started learning it yesterday and i gotten decently far i think for a day i learned if statements , varaibles, strings boolens down so far and plan on learning arrays and procedures next but right now im facing a issue i dont understand first heres my code

  1. string name = Console.ReadLine(“what is your name “);
  2. int age = Convert.ToInt32(Console.ReadLine(“hello”+ name + “how old are you?: “));
  3. Console.WriteLine(“you are ” + age + “years old “);
  4. int year = 2018 – age;
  5. Console.WriteLine(“you Were born in the year: “);

so from my understanding ReadLine is used to read userinput so i assume there is a way it can be used multiple times but yet when i put readline in again i get the error no overload for method ReadLine

submitted by /u/Joeynuma
[link] [comments]

Leave a Reply