aboutsummaryrefslogtreecommitdiff
path: root/engines/director/lingo/tests/math.lingo
blob: 9c0b2d57a3df1baa89526f371e07e7cd80755a96 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
if random(4) > 2 then put 1000
set z = 5.5
set z1 = 2
set z2 = z / z1
put z
put z1
put z2
put integer(z2)
put cos(z2)

set x = 2 + 3 * (4 / 2)
put x

put power(2, 8)
updatestage

-- Type conversion
put (1024/4096)*100         -- 0
put (1024/4096)*100.0       -- 0.0
put ((1024*1.0)/4096)*100.0 -- 25.0