1int x,y,z;
2
3void setup() {
4
5pinMode(2,INPUT);
6pinMode(3,OUTPUT);
7pinMode(4,OUTPUT);
8pinMode(5,OUTPUT);
9pinMode(6,OUTPUT);
10pinMode(7,OUTPUT);
11pinMode(8,OUTPUT);
12pinMode(9,OUTPUT);
13}
14
15void loop() {
16
17 x=0;
18
19 y=x++;
20 delay(1);
21 x=y++;
22 delay(1);
23if (x==6)
24{delay(1)
25int x=1;}
26if(digitalRead(2)==HIGH&&x==1)
27{digitalWrite(3,HIGH);
28digitalWrite(4,HIGH);
29digitalWrite(5,LOW);
30digitalWrite(6,LOW);
31digitalWrite(7,LOW);
32digitalWrite(8,LOW);
33digitalWrite(9,LOW);
34}
35if(digitalRead(2)==HIGH&&x==2)
36{digitalWrite(3,LOW);
37digitalWrite(4,HIGH);
38digitalWrite(5,HIGH);
39digitalWrite(6,LOW);
40digitalWrite(7,HIGH);
41digitalWrite(8,HIGH);
42digitalWrite(9,HIGH);
43}
44if(digitalRead(2)==HIGH&&x==3)
45{digitalWrite(3,LOW);
46digitalWrite(4,LOW);
47digitalWrite(5,HIGH);
48digitalWrite(6,HIGH);
49digitalWrite(7,HIGH);
50digitalWrite(8,HIGH);
51digitalWrite(9,HIGH);
52}
53if(digitalRead(2)==HIGH&&x==4)
54{digitalWrite(3,HIGH);
55digitalWrite(4,LOW);
56digitalWrite(5,LOW);
57digitalWrite(6,HIGH);
58digitalWrite(7,LOW);
59digitalWrite(8,LOW);
60digitalWrite(9,HIGH);
61}
62if(digitalRead(2)==HIGH&&x==4)
63{digitalWrite(3,HIGH);
64digitalWrite(4,LOW);
65digitalWrite(5,LOW);
66digitalWrite(6,HIGH);
67digitalWrite(7,LOW);
68digitalWrite(8,LOW);
69digitalWrite(9,HIGH);
70}
71if(digitalRead(2)==HIGH&&x==5)
72{digitalWrite(3,HIGH);
73digitalWrite(4,LOW);
74digitalWrite(5,HIGH);
75digitalWrite(6,HIGH);
76digitalWrite(7,LOW);
77digitalWrite(8,HIGH);
78digitalWrite(9,HIGH);
79}
80if(digitalRead(2)==HIGH&&x==6)
81{digitalWrite(3,HIGH);
82digitalWrite(4,HIGH);
83digitalWrite(5,HIGH);
84digitalWrite(6,HIGH);
85digitalWrite(7,LOW);
86digitalWrite(8,HIGH);
87digitalWrite(9,HIGH);
88}
89
90
91}