Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
26
Task/Integer-comparison/Oberon-2/integer-comparison.oberon
Normal file
26
Task/Integer-comparison/Oberon-2/integer-comparison.oberon
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
MODULE Compare;
|
||||
|
||||
IMPORT In, Out;
|
||||
|
||||
VAR a,b: INTEGER;
|
||||
|
||||
BEGIN
|
||||
In.Int(a);
|
||||
In.Int(b);
|
||||
IF a < b THEN
|
||||
Out.Int(a,0);
|
||||
Out.String(" is less than ");
|
||||
Out.Int(b,0);
|
||||
Out.Ln;
|
||||
ELSIF a = b THEN
|
||||
Out.Int(a,0);
|
||||
Out.String(" is equal to ");
|
||||
Out.Int(b,0);
|
||||
Out.Ln;
|
||||
ELSIF a > b THEN
|
||||
Out.Int(a,0);
|
||||
Out.String(" is greater than ");
|
||||
Out.Int(b,0);
|
||||
Out.Ln;
|
||||
END;
|
||||
END Compare.
|
||||
Loading…
Add table
Add a link
Reference in a new issue