I have an application that calculates your gold per minute farmed.
I want to make an error report that wouldn\'t allow you to insert any text in the console input where yous hou
Instead of using int.Parse, you can use int.TryParse, and print a message:
int gold;
while(!int.TryParse(Console.ReadLine(), out gold))
{
Console.WriteLine("Please enter a valid number for gold.");
Console.WriteLine("Inesrt your gold: ");
}
This allows you to re-prompt and handle errors correctly.