IDE exercise anatomy

Learn about the different parts of an IDE exercise and how those map to what a student sees on Campus.

Ramnath Vaidyanathan avatar
Written by Ramnath Vaidyanathan
Updated over a week ago

There are many parts to an IDE exercise and they are each meant for a different part of the student experience. View the screenshot below of an IDE exercise on Campus and see how the different parts of the finished exercise map to what you build in Teach.

Content Blocks

Title: The exercise title will be available just above the exercise's context block and should clearly convey the objective of the exercise.

Instructions: The instructions for the exercise are located underneath the context section. Ensure that you do not have portions of the instructions in the context, as this requires students to go back-and-forth between the two sections. Instructions should be short, but should also require students to think about how to approach the problem.

Hint: Students ask for this when they need help with an answer. Students must click "Show Hint"  or use Ctrl + H   to receive this information. Hints should get students 50% of the way to the answer. Note: Many instructors confuse hints with SCT feedback messages, which are returned following an incorrect submission. SCT feedback messages are generated when a student submits an incorrect solution.

Sample code: The sample code appears as files in the IDE window on the right-hand-side of an exercise. This is where the student will fill in the code and then submit. The solution submitted from the script window is called the "student submission." The sample code is written as YAML key-value pairs, where each key corresponds to the name of a file, and the values are objects that specify the contents of the file.

script.py:
  content: |
    # Print 'Hello World!' below
    print('Hello World!')

Solution code: This is the expected solution and is used to check the student submission. The solution code is specified as YAML key-value pairs, where each key corresponds to the path of a file in the solution, and the values are objects that specify the contents of the file, and whether or not the file should be open when the exercise is initialized.

hello_world/script.py:
  open: True
  content: |
    def greet():
        print('Hello World!')
hello_world/README.md:
  open: True
  content: |
    # Hello World!

Success message: The success message is returned to a student upon the successful completion of an exercise. An ideal success message focuses on insights, not praise.

Submission Correctness Tests (SCTs). SCTs check whether the student submission is correct. If a student's submission is correct, the success message is returned. If the student submission is incorrect, a feedback message, with the heading "Incorrect Submission" will be returned to the student. This feedback message will include information that directs students to the portion of the exercise that they got wrong and also highlight it in the script window. If there are multiple errors in the code, the SCTs will throw the first error message only.

Did this answer your question?