ack/lang/a68s/test/tarith.8

22 lines
914 B
Groff
Raw Permalink Normal View History

1988-10-05 13:29:42 +00:00
00050 .PR POINT .PR
00100 .BEGIN
00110 PRINT(("A",.ABS-2.0,.ABS 2.0,NEWLINE,
00120 SPACE,1.1+2.2,NEWLINE,
00130 "D",1/3,1.1/3.3,NEWLINE,
00140 "E",.ENTIER 3.3,.ENTIER-3.3,NEWLINE,
00150 SPACE,2^9,13^2,1.3^2,3.0^3,3.0^-2,NEWLINE,
00160 "G",2R110>=2R100,2R0>=2R1,2R100<=2R110,2R1<=2R0,NEWLINE));
00170 PRINT(("M", 4%3,4.MOD 3,-4%3,-4.MOD 3,4.MOD-3,NEWLINE,
00180 SPACE,6*8,NEWLINE,
00190 "R",.ROUND 2.45,.ROUND 2.55,.ROUND-2.45,.ROUND-2.55,NEWLINE,
00200 SPACE,1.1-2.2,NEWLINE,
00210 "S",.SIGN 3,.SIGN 0,.SIGN-5,.SIGN 3.3,.SIGN 0.0,.SIGN-3.4,NEWLINE));
00212 PRINT(("H", .ABS(2R101.SHL 1),.ABS(2R101.SHR-1),.ABS(2R101.SHR 1),.ABS(2R101.SHL-1),
00214 .ABS(8R177777.SHL 16),.ABS(8R177777.SHR-16),NEWLINE,
00220 "W",.REAL(2),NEWLINE));
00230 .LOC.INT I :=1,.LOC.REAL X:=1.0;
00240 PRINT(("B",I+:=2,I%*:=2,I*:=6,I%:=3,I-:=1,NEWLINE,
00250 SPACE,X+:=2,X*:=6,X/:=2,X/:=2.0,X-:=1,NEWLINE));
00260 .SKIP
00270 .END