The aim of this code is to repeat the question "Please enter your name" if the user does not input any data. However I am having trouble with making this work with the if statement.
while (true)
{
Console.WriteLine("Please enter your name:");
string line = Console.ReadLine();
if (line=String.empty) //I'm having difficulty making this a valid statement
Console.WriteLine("Your entry was blank");
else break;
}