The instructions for Task 2 do not state the position of the locomotive in the wagon list. This causes confusion for learners trying to solve the task from the written instructions alone.
The current instructions state two facts:
- First, the locomotive always has an ID of 1.
- Second, the first two wagons in the list must move to the end.
The instructions do not state where the locomotive sits relative to those first two wagons.
Learners are only able to identify a locomotive’s position by referring the example code or the test file. In both, the locomotive sits at index 2, after the two wagons that must move. I checked all four cases in locomotive_engineer_test.py. The locomotive sits at index 2 in every case. Because the instructions are ambiguous about the locomotive’s position relative to the first two wagons in the first list (each_wagons_id), the locomotive’s fixed position at index 2 has to be inferred by examining the code.
The locomotive’s position is not a small detail. It is the fact that lets a learner unpack the list correctly. Without it, a learner must guess at the list structure, or read the test file before they read the instructions. That’s not the point of the exercise.
I suggest one added sentence in the instructions, for example:
“The two new wagons always appear as the first two items in the list. The locomotive (ID 1) always follows as the third item.”
This change maintains the task’s challenge. It removes the need to discover the list structure from the test file.
I wanted to find out if other learners also found this confusing. I also wanted to know if a track maintainer would be able to add this detail to the instructions.