Tested it a lot of times but still giving unexpected error
using System;
class Program
{
public static void Main (string[] args)
{
Random numGen = new Random();
public int generatedNum = numGen.Next(0, 64);
Console.WriteLine(generatedNum);
} }
} }

1 Reply
Local variables cannot be public or private
Local variables are local