☰ Year plan · Communication Technology

The AND simulator in VB.NET

Week 9 · Unit 2 Topic 2: AND gate simulation project with VB.NET: purpose, stages, controls, code in three parts · 3 lessons
Answers are for parents and teachers.
1
Trace the correct code from the start state for the clicks A, A, B. Give the state after each click.
2
Trace the clicks B, A, B, B. Is the lamp lit at the end?
3
Trace the clicks A, B, A, A, B and give the final state.
4
Fill the gaps in SwitchB_Click: If SwitchB.Text = "Off" Then SwitchB.Text = "On" : If ____ Then ShowLamp(True) : Else SwitchB.Text = ____ : ShowLamp(____).
5
What is the smallest number of clicks that lights the lamp from the start state? Name two ways.