1. Explore the controls
Change the inputs and observe the model's response.
Find the first matching value in [4, 7, 2, 9, 5].
Change the inputs and observe the model's response.
for i, value in enumerate(items):
if value == target: return i
return -1Adjust the controls to obtain the following output. Multiple valid solutions may exist.
The fourth item has index 3.
Simplified educational model. No real hardware is controlled. Code examples are illustrative and not executed as arbitrary programs.