-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathextraTest2.w
More file actions
45 lines (44 loc) · 836 Bytes
/
extraTest2.w
File metadata and controls
45 lines (44 loc) · 836 Bytes
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
{Extra Test2 : Program to test the following extra features:
1) OR '|' in boolean expression
2) less than '<' in arithmetic relation
3) greater than '>' in arithmetic relation
4) greater than or equal to '>=' in arithmetic relation
5) inequal '!=' in arithmetic relation
6) Bitwise xor '^' in arithmetic operation for intergers
7) division '/' in arithmetic opetrations
}
write(true|false);
writeln;
write(true|(true&(!true)));
writeln;
write(2 < 3.5);
writeln;
write(2 < 23);
writeln;
write(3.5 < 1.1);
writeln;
write(2 > 3.5);
writeln;
write(2 > 23);
writeln;
write(3.5 > 1.1);
writeln;
write(2 >= 3.5);
writeln;
write(2 >= 23);
writeln;
write(3.5 >= 1.1);
writeln;
write(2 != 3.5);
writeln;
write(2 != 2);
writeln;
write(3.5 != 1.1);
writeln;
write(2^2);
writeln;
write(4/2);
writeln;
write(3/1.5);
writeln;
write(4.5/0.9)