-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtest9.txt
50 lines (44 loc) · 888 Bytes
/
test9.txt
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
program calculator(input, output);
var num1, num2: integer;
var num3: real;
var result: real;
var aResult: array[10..70] of integer;
function sum (num1: real; num2: integer):real;
begin
result := num1 + num2
end;
function subtraction (num4: real; num5: integer): integer;
begin
result := num1 - num2;
result := num4 - num5;
subtraction := result
end;
function multiplication (num4: integer; num7: integer): integer;
begin
result := num1 * num2;
result := num4 * num7
end;
procedure procId;
begin
result := num7
end;
begin
num1 := 2;
num2 := 10;
result := 0;
result := sum(num1, num2);
if result > 20 then
result := subtraction(num2, num1)
else
begin
num1 := 3;
num2 := 4;
result := multiplication(num1, num3)
end;
while (multiplication(num1, num2) <> 100) do
begin
num1 := num1 + 1;
num2 := num2 + 1;
aResult[50] := num1 + num2
end
end.