Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.0k views
in Technique[技术] by (71.8m points)

save - Saving and reopening Visual Studio

so i made a simple prog in visual studio.

When I closed down the project it was 100% working

Now having reopened the project it tells me there are errors and wont run

The error codes are CS0101 and CS0111

The prog looks like this


namespace ConsoleApp4
{
    class Program
    {
        static void Main(string[] args)
        {
            Start:
            Random rd = new Random();
            double num01 = rd.Next(10,20);
            double num02 = rd.Next(1,10);
            double ans;
            Console.WriteLine("~Press Any Key to Generate Numbers~");
            Console.ReadKey();
       
            Console.WriteLine($"What is {num01} divided by {num02}");
            
            ans = Convert.ToDouble (Console.ReadLine());
            if (ans == (num01/num02))
            {
                Console.WriteLine($"Congratulations you are correct!! {num01/num02} 
 ~Press Any Key to try again~");
                Console.ReadKey();
                    goto Start;
            }
            else
            {
                Console.WriteLine($"You are incorrect! The correct answer is {num01/num02} ~Press Any Key to try again~");
                Console.ReadKey();
                goto Start;
            }
        }
    }
}
question from:https://stackoverflow.com/questions/66059842/saving-and-reopening-visual-studio

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

Project was duplicated >_<


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...