We're more than willing to help anyone with a genuine problem but we will not do your homework for you!
The first problem is that you have tagged your question as "C#" but you have posted what looks to be C++. One of the things you will need to learn as you go through your course is to be precise.
If you have not been taught the basic syntax of C++ (such as what a main function should look like, how are statement blocks terminated, how to use standard functions like printf) then you really need to start at the beginning of your course reference material, or talk to your tutor.
If you do not have access to a compiler then you could try one of the on-line ones (e.g.
https://www.tutorialspoint.com/compile_cpp_online.php[
^] )
Hint: Only try to fix the very first compilation error each time - many of the subsequent errors reported will disappear when you fix the first one.
Once you have something that can run, don't just look at the answer. Walk through the program with a pencil and paper and work out the interim steps for yourself