Task 1: Getting Started

Let’s set up the assignment on our computer and learn about its basic structure.

  1. Find Assignment #0 in Canvas and click on the invitation link. After accepting the assignment on the Github Classroom page, go to your assignment repository on GitHub.

  2. Follow the instructions to clone your repository and open it in Visual Studio.

  3. When the solution opens, check out the contents of the Solution (Mac) or Solution Explorer (Windows). You will find two projects within the solution:

    • The HelloWorldAutoGraded contains the code that you will work with for this assignment.
    • The Hello.Tests project contains auto-grading tests. You do not need to change any of the code in the testing project.
    Note

    If you do not see the Solution Explorer, you can open it by selecting the View option in the toolbar.

    • Windows Users: View > Solution Explorer
    • Mac Users: View > Solution

    Review the Visual Studio walkthroughs from chapter 1 if you need help navigating Visual Studio.

  4. Inside HelloWorldAutoGraded, open up the SayHelloClass.cs class. This is where you will write any code for this assignment. Within this class, you will see the following:

    • The SayHello() method which is returning &&&.
    • SayHelloClass() constructor which is empty. This will remain empty for this assignment.
  5. Now, turn your attention to Program.cs in the HelloWorldAutograded project. This class will print two strings to the console using the Console.WriteLine() method.

    • The first returns the string value of the SayHello() method from the SayHelloClass.
    • The second returns the data type of the SayHello() method’s output.
  6. You are now ready to run the program. Do the following:

    • Mac Users: Hit the Run button at the top left-hand corner of the window. Right-clicking on the HelloWorldAutograded project and selecting Run Project will also work.
    • Windows Users: Click on the solid green triangle next to the name of the HelloWorldAutograded project. You can also press F5 to run the project.
  7. Visual Studio opens a pane and displays any program output when you run a program. Currently, the program output contains the following:

    &&&
    System.String
    
  8. You are ready to run the auto-grading tests.

You are now ready to move on to Task 2: Running the Auto-grading Tests .