Hey I'm very very new to programming and I need help with this code im trying to write a simple program that asks you your name, age, and the date, then ask if the information is correct what I'm trying to do is make it see whether they respond with Yes or No, but I'm getting a CS1501 error and I don't know how to fix it. Please help if you can.
Heres the code, the error is the only thing fully capitalized
using System;
namespace Meem_machine
{
class Program
{
static void Main(string[] args)
{
Console.Write("What is your name? ");
string name = Console.ReadLine();
Console.WriteLine("Hello " + name);
Console.Write("How old are you? ");
string age = Console.ReadLine();
Console.Write("What is the date today? ");
string date = Console.ReadLine();
Console.WriteLine("Your name is " + name + " and you are " + age + " and the date today is " + date);
Console.Write ("Is this correct?") ;
if (Console.READLINE("yes"))
{
Console.WriteLine("Welcome" + name);
}
}
}
}
3 Replies
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Rafnas T PPosted Apr 9, 2018, 11:38 AM
Chirag KhabariaPosted Apr 9, 2018, 11:26 AM
Tushar DikshitPosted Apr 9, 2018, 11:21 AM
HI,
You must be getting error when you compile the code. The error is due to , you are passin argument to ,