All Collections
Courses
Course Development
Authoring Drag and Drop exercises
Authoring Drag and Drop exercises

Learn how to author the Solution and SCT blocks for a Drag and Drop exercise

Carl Rosseel avatar
Written by Carl Rosseel
Updated over a week ago

In this article, you will learn how to create Drag and Drop exercises.

The Context, Instructions, and Hint blocks are written like Coding exercises. See

Solution block

The solution for a Drag and Drop consists of drop zones and items that belong to each drop zone. For every drop zone, you will need to define values for the following keys:

  • title: The title of the drop zone, visible to learners.

  • content: The content shown on the card.

  • Incorrect message: The message that pops up for the learner when he/she presses submit an answer and the item is incorrectly placed.

  • Success message: The message displayed to the learner when he/she submits an answer and the exercise is correct.

  • Language (optional): Used in Parsons Drag and Drop exercise to provide language highlighting

  • offset (optional): Used in Parsons Drag and Drop exercise to indicate the correct indentation level for that item (line of code).

  • maxOffset (optional): Used in Parsons Drag and Drop exercise to indicate the maximum indentation level.

Classify Drag and Drop exercise

Shown below is a sample solution block for a Classify Drag and Drop exercise. There is one drag zone, that holds all the options. You can add up to four drop zones. Each drop zone contains a list of items, each with an id and content. These will be shown in a random fashion. The number of items depends on the exercise, and a good exercise ranges anywhere between 4-12 cards. Note that 12 cards are the absolute maximum. These will be shown in a random fashion.

Order Drag and Drop exercise

In the case of an Order Drag and Drop exercise, there is no drag zone and only a single drop zone. The different options that need to be ordered are in the list of items.

Parsons Drag and Drop exercise

In the Parson's variant of the Drag and Drop exercise, learners can order and indent the items to complete the code. Accordingly, the solution can specify the maximum indentation level using maxOffset and the correct indentation level for each line of code using offset.

Did this answer your question?