Example "Transport" - Use of Random Parameters

Last modified by Carina Enke on 14.01.2024

As an example, a typical application task is created. The goal is to calculate the distance travelled by a vehicle based on speed and time. The speed is dependent on the vehicle type.

 

Editor - Tab Variablen zur Beispielaufgabe_de.png

In the example, the text variable {transport} will be randomly initialised with one of the following values: "bike", "bus", or "train". The numerical variable {speed} is randomly selected from a value range. Thus, the value range for the speed {speed} should be set in dependence of the selected vehicle {transport}, since a "bike" is generally slower than a "train".

Editor - Beispiel einer Bedingung_de.pngEditor - weiteres Beispiel einer Bedingung_de.png

For the dependent value setting, we use the variable condition. In the condition, we can define the value range for the variable {speed} depending on the selected value of the variable {transport}. For the bike ({transport}="bike"), for example, a value range of 10 to 30 (km/h) was set.

Editor - Nutzung von Variablen in der Aufgabenstellung_de.png

The given values of the task are integrated into the task text by specifying the variable name ({transport}, {speed}, and {hours}). In the example, the variable is included in a task of the type calculation interaction.

The variable with the correct solution {distance} is bound to the gap.

Testrun - Beispielaufgabe im Testrun_de.png

One of the defined values will be randomly chosen for each participant and each test attempt. In the example, the value "bike" was randomly inserted, which is why a speed in the value range of 10 to 30 (km/h) was selected.