.


:




:

































 

 

 

 





1.

2. , .

3. .

4. , .

 

22. 7

23. . .

 

(, ). , , ( ). , , , (, ). .

, . , . , (). .

, , , . , .

( ). , - . - . , . , . , .

, . ? , . . , : , , . .. , , .

, . integer. , -32768 32767. integer 2 , 16 , , 216 (65536) ( , ). x, y b .

var x, y, b: integer; begin write ('Input first number: '); readln (x); write ('Input second number: '); readln (y); writeln ('x = ', x, ', y = ', y); writeln ('Changing values... changing values...'); b:= x; x:= y; y:= b; writeln ('x = ', x, ', y = ', y); readln end.

, , .

, - . . , . , .

, . . , , , . , - , .

- , . , , . , , , , , , :

) ;

) , (, +3.14 -19-5);

) - false true ( );

) - , (, '<>', 'Y');

) - , (, ' ', ' "').

- , ( ) .

 

:

const pi = 3.14; var r, l, s: real; begin write ('? '); readln (r); l:= 2 * pi * r; s:= pi * r * r; write (': ', l:5:1, '. : ', s:5:1); readln end.

, . . , GOTO: , , . , . : GOTO <>. GOTO - ( [ ]); <> - . - , . . . , . , . LABEL (), :

label

loop, 1b1, 1b2;

begin

.......

goto 1b1;

.......

loop:......

.......

1b1:1b2:......

........

goto 1b2;

.......

GOTO .

:

, GOTO, - ;

, (), , () .

 

24. MS DOS :

1. , COMMAND.COM (, dir, copy).

2. - , . (, , , ).

, , , . .

copy con _

. Enter. - Ctrl Z, Enter.

del ( ) _

, .

ren ( ) _1 _2

_1 - , .
_2 - , .
, .

copy _ ( ) _1

, .

A: -

C: -

dir ( )( _ ) (/p) (/w)

, ( , ). /p , , - . . /w .

cd md rd

25. . .

- . . ,

2.1. < >:= <>;

: k:= 7; i:= sqr(k); n:= k * i;

k:= 7 k 7, i:= sqr(k) i k2, .. 7 * 7 = 49, n:= k * i n k * k2, .. 7 * 49 = 343.

k:= k + 1, , k, , k. .

2.2.

:

if <> then < 1> else < 2>;

: if x <= 0 then y:= - a * x else y:= b * exp(x);

. if, then else . , if , (, ), then. , (, ), else. if-then-else if-then-else.

( , else). , then, , , .

.

, .

:

goto <>;

- "" , . , 4 ( 1 9999), . , . , , Label, , .

goto , goto. , , , .

2.4. begin end.

:

begin < 1>;...; < N> end;

begin end " ", . , .: if x < 1 then begin y:= 1 - x; z:= sqr(x) end else begin

y:= 1 + x; z:= ln(x) end;

.

:

Case <> of

,..., : < 1>;

,..., : < N>;

end;

else , , .

, . case end .

s ( a, a b, d1 d2, a h1, a b h2), .

program ploshad;

Var a, b, d1, d2, h1, h2, s: real;

n:1..5;

Begin

read(n, a, b, d1, d2, h1, h2);

case n of

1: s:= sqr(a);

2: s:= a * b;

3: s:= d1 * d2;

4: s:= a * h1;

5: s:= ((a + b) * h2) / 2;

end;

writeln(' =',s)

End.

 

26.





:


: 2016-11-12; !; : 750 |


:

:

.
==> ...

1800 - | 1663 -


© 2015-2024 lektsii.org - -

: 0.021 .