Respuesta :
1. Create a variable, let's call it "parking_spots". Set it to 16 (8 for each floor).
2. Create a variable, let's call it "current_floor". Set it to 1.
3. Create a variable, let's call it "max_floor". Set it to 2.
4. Create a variable, let's call it "open_gate". Set it to 0.
5. Create a loop that will run continuously.
6. Within the loop, read the input from the weight sensors.
7. If the weight sensor input is greater than 0, increment the "parking_spots" variable.
8. If the "parking_spots" variable is greater than 0, open the gate (set "open_gate" to 1).
9. If the "parking_spots" variable is 0, do not open the gate (set "open_gate" to 0).
10. Display the number of parking spots on the seven seg display.
11. If the "open_gate" variable is 1, open the gate and display the floor to
what do you mean by variable?
A variable is a symbolic name associated with a value that can be changed. In programming, a variable is a location in memory used to store a value that can be modified during program execution. Variables are often used to store user input, program results, and other values. Variables have a type, name, and value, which can be changed or updated during program execution. Variables are essential in programming as they allow us to store and manipulate data.
To learn more about variable..
https://brainly.com/question/17169621
#SPJ4