-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.ts
50 lines (50 loc) · 1.1 KB
/
main.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
input.onButtonPressed(Button.A, function () {
Antal += 1
basic.showNumber(Antal)
for (let index = 0; index < Antal; index++) {
basic.showLeds(`
. . . . .
. . . . .
. . . . .
. . . . .
. . . . .
`)
basic.showLeds(`
. . . . .
. . . . .
. . # . .
. . . . .
. . . . .
`)
basic.showLeds(`
. . . . .
. # . # .
. . # . .
. # . # .
. . . . .
`)
basic.showLeds(`
# . . . #
. # . # .
. . . . .
. # . # .
# . . . #
`)
basic.showLeds(`
# . . . #
. . . . .
. . . . .
. . . . .
# . . . #
`)
basic.clearScreen()
}
basic.showNumber(Antal)
})
input.onButtonPressed(Button.B, function () {
Antal = 0
basic.showNumber(Antal)
basic.showString("Hej Clapton")
})
let Antal = 0
basic.showString("Hej Clapton!")