Skip to main content
Using Alternate Exercises

Use different versions of CodeHS assignments in your courses

Sara Jenis avatar
Written by Sara Jenis
Updated this week

Alternate exercises are different versions of existing assignments in CodeHS courses. These assignments are changed in subtle ways so that the core concept and difficulty are not altered, but a different solution is required. You can switch out assignments while keeping the layout and numbering of your course the same.

Alternate exercises are available in the following courses:

  • Introduction to Computer Science in JavaScript (Golden)

  • AP Computer Science A (Nitro)

  • AP Computer Science Principles in Python

  • AP Computer Science Principles in JavaScript

  • Intro to Programming with Karel the Dog (Ace)

  • Web Design

  • Intro to Computer Science in Python 3


Example Exercise

Below is an example of a default and alternate problem description from the AP CSA (Nitro) course:

Default Exercise

Alternate Exercise

Your task is to write a program that takes the month of the year as an integer and output if it is "Spring spawning season", "Fall spawning season", or "Not spawning season".

The spring spawning season lasts from March to June (months 3 - 6). The fall spawning season lasts from September to November (months 9 - 11).

Your task is to write a program that takes the month of the year as an integer and output if it is "Spring spawning season", "Fall spawning season", or "Not spawning season".

The spring spawning season lasts from April to June (months 4 - 6). The fall spawning season lasts from October to December (months 10 - 12).

Applying Alternate Exercises

Configure tools and Forking an assignment are available for teachers on a CodeHS Pro license.

  1. Navigate to the Assignments app for your Course or Section.

  2. Click the three dots "..." next to the assignment you would like to apply an alternate exercise to.

  3. Choose Remix. If the exercise does not have an alternate, the option will be greyed out.

  4. A window will pop up with a description of the alternate exercises available. Select Use Alternate Exercise to change the assignment or click Preview to preview the new exercises.

  5. After selecting your alternate exercise, you'll be provided with two options:

    1. Create New Assignment: Original assignment remains in the course and the new assignment is created after it.

    2. Replace Current Assignment: Original assignment is removed from the course and replaced with the new assignment.

  6. Then, Remix Assignment!

gif shows selecting alternate exercise pop up

Switching Back to the Default Exercise

You can switch back to the default exercise by navigating to the same menu in the procedure above. This menu displays which exercise you are currently using.

  1. Navigate to the pop-up menu displaying alternate exercises.

  2. Select the original exercise.

  3. Click on Use This Activity.

  4. Select Replace current assignment.

  5.  Click Remix Assignment in this menu to revert back to the default version.

image showing how to switch back to the default exercise

Note: If students have completed the default version of an assignment before an alternate is applied, their grade will still appear in the Gradebook. However, if the student revisits the assignment, they will see the alternate version.


Still have questions? Contact our team at hello@codehs.com to learn more!

Did this answer your question?