. , , ,

,,,

- — ,



. , ...

_______________ ..

“____ ” ________________ 1999 .



-” -


( )


, ...

_________ ..


_________ ..


1999


, . , , - - .

“-” , -, , . () , - . .

:

  • MS-DOS 3.x ;

  • Windiows 95, Windows 98 Windows NT.

, Borland C++ 3.1 ( Turbo C 2.0). , Borland C++Builder 3.0.


5

1. 7

1.1. 7

1.2. . 9

2. 10

2.1. 10

2.2. 10

3. - 12

3.1. - 12

3.2. 13

3.3. 15

3.4. 15

4. 19

4.1. 19

4.2. 22

4.3. 23

4.3.1. 23

24

24

24

24

24

24

4.3.2. 25

4.3.2.1. 25

4.3.2.2. 26

4.3.3. 28

4.3.4. () 28

4.3.4.1. 29

4.3.4.2. , 30

4.3.4.3. 32

4.3.5. 35

4.4. 36

4.4.1. 36

4.4.2. 37

4.4.2.1. MS-Dos 37

4.4.2.2. Windows 41

4.5. 47

49

50

51

1: - 51

2: 53

3: 59


, , . .

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

, (), -. : “ , , ” [1]. . . - , . - “” .

- , . , - , , , - . , , -, , .

: -. . , - . , .

, , , , -, , , .

, - , () , , , .

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

-, , -.

, , , . , , , , , .

1.

1.1.


(), ().

, , , , , , .

, , . , . , . - . , . , .

, . . :

  • - ,

  • - .

- , , -.

- . - . , , .

(), -. (<< >>).

, , . . , , () .



, , , . (<< >>). , . , - , .

- . - , -.

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

- , . “” , , .

- , , . - . , , , . .

- , , . , . .

, , . , , . . , , .


1.2. .


- , , , . , . - , .

- . . . , - .

, . , , ..

2.

2.1.


, , . , . .

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

, , , .

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

, , , .


2.2.


. , . , , . - , .

, , . , , , , , .

, , . , , , .

, . , () , , . : , , ; , .

. , , , , .

. , , . , , , . .

3. -


. , - . , - .

, . - , .

“ , , ” [1].

- :

-, (: Page Maker, Corel Draw, Word ..) :

1. , , , , .

  1. , .

-, ( ) , .

. :

  1. - (“” ),

  2. -.

-, . 1 .


3.1. -


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

, - ( ), . .

- , .

, . 3.3.


















.1. - .


3.2.


-. , - . , , .

1 - .

1.





BEGIN





END






AD




PP





IF





INPUT





OUTPUT





CASE





SWITCH





LABEL





GOTO


.

-. . , “” .

, , - . , , “” .

, , . :

  • , ;

  • , “-”;

  • .

, .

. .

/ ” , .

, “”. . - “”.

, . - “”.

. -, , ( ).

, . “” ( ).

“” “”. “” , , “.”


3.3.


- - , - .

- :

  • “” - ;

  • “” .

- : “ ” “”. .

, “”. “”. , “”.


3.4.


, -. :

  • ( );

  • Pascal ( ).

. :

1, 2, ... , N;

N+1, ...;

:

  • int - ;

  • long_int - ;

  • float - ;

  • char - .

- C, Pascal. .

.

, , , , :

+ ,

- ,

* ,

/ ,

= ,

sin ,

cos ,

tg ,

ctg ,

arcsin ,

arccos ,

artg ,

arcctg ,

ln ,

lg ,

abs (),

exp ,

mod ,

div ,

^ ,

sqrt ,

sh ,

ch ,

th ,

, , "-":

randomize() ,

random() ,

clock() ,

getch() ,

kbhit() ,

strlen() ,

..

( ). Pascal ( ). . “;”

:


, “;”. - &&, - ||, - !.

:



. “;”

:


:

“”, 1, “”, 2, ... , N;

“”, N+1, ...;

, , . “;”.

:


“;” .

:



.



.

:


“switch” . , .

:


“” “”. . “” , , “”.



, .

4.

4.1.


.. - , “” -. -:

  • ( , );

  • ;

  • ;

  • ();

  • .

, .

. , - . , . (X,Y). (X,Y) , (0,0) - ( “-”).

(.2.).



.2.


, -.

, , -, , , , N_X N_Y, N_X - X, N_Y - Y.

, . 1.



Y X0 X1 640


Y0

J


N_Y


Y1

J+N_Y N_X


X

I I+N_X 480


1.


- . , 640 480 pixel, , 1, - (X0,Y0) (X1,Y1).

, , , . :

height =(Y1-Y0)/N_Y; 

width =(X1-X0)/N_X; 

.

, , I~I’ J~J’, , , (I,J) (X0,Y0), , , I~I’=0 J~J’=0. (I+N_X,J+N_Y), , , (X1-width,Y1-height) , (I+N_X)~(I’+N_X)=N_X (J+N_Y)~(J’+N_Y)=N_Y.

( i , j), ( i , j) [I,J,I+N_X,J+N_Y] :

X = X0+(i-I)*width;

Y = Y0+(j-J)*height;

X,Y (i , j). , . , .

. , , .

.

“-”, , , - . “” . , “”.

, . . , . :

, ( ) - . (I, J) , , .

MS-Dos:

- 

- 

- 

- 

.

, “” “” “” . , , “” “” .

( , ) “” :

- ;

- .

.

: c , , , “” “” .

Windows . , Windows [10].


4.2.


, , - .

Windows , Borland. :

  • ;

  • ;

  • ;

  • ( );

  • ;

  • .

, MS-Dos, , ( ), . 1104 -.

. .

4.3.


? , . , , , , .


4.3.1.


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

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

, . . , . . , , , , .

, .

. , , , , . , . , . , .






















()



, , , .

, . , .

, .

. , , . , , , , , .

, , :



















.


4.3.2.

4.3.2.1.


, , .

( ) : , , begin, end . , , , .

:

  1. , , ;

  2. ( );

  3. , .

. . .

( , ) . , .

, , - . , begin x else begin (), , : x begin begin else . +end, +/, *[ - . () .


4.3.2.2.


, : , .. . , , . , .

. , . , , . , .

, .

: s1, s2, s3,, sn.

s,i L,t

L , t .


0, int

1, long_int

t= 2, float

3, char

4,

-1, ,


, :


si k

1, si

2, si

3, si `

k= 4, si “ ”

5, si

0, si


: ( ).





























.3. .


:

  1. .

  2. , .

- (.3.).

, . .


4.3.3.


, . .

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

:

<> = <>

.

, . . , . . .


4.3.4. ()


- , . . . . , , , .

(). , .

:

: x=a+f*c;

:xafc*+=.

, , . .


4.3.4.1.


, . ( ).

, .

:

  1. , .

  2. , .

2.1. , ,

2.2. : 0, , .

2.3. , .

2.4. , .

  1. ( ).

( - 0 2.2.

) 1 (, .

  1. ( ;) : .

.

: (x+a)*(x-b)+3;

:











x a x b


: x a + x b - * 3 +.

, , .


4.3.4.2. ,


. :

a[i+1]-b[i,j-1]*a[2*i+1]



.

.

, :

a: array [1..n] of integer; // Pascal

int a[n]; // C/C++

k-.

A . . .


A +k +2k +3k A+k*(i-1)

k


a[i] +k*(i-1) , C/C++ a[i] A+k*i. k ,

a[i] -----> A+k*(i-1) (1)

a[i] -----> A+k*i (1’)

:

b: array [1..m,1..n] of integer;// Pascal

int b[m][n];//

i,j :

b[i,j] -----> B+k*((i-1)*n+(j-1)) (2)

b[i,j] -----> B+k*(i*n+j) (2’)

( ) :

  1. , .

  2. .

: (1)-(2’).

: a i 1 + ... b i j 1 ... a 2 i * 1 + ... * -

, . : k], k - .

: a i j + 2] b i j 1 3] a 2 i * 1 + 2] * -.


: ( )


-



... *



+ ... ...



i 1 b i a +



i j * 1


2 i


, :


:


  1. [, 0 [k, k ...

  2. , , 1 [k k 1: k=k+1; , .

  3. ], 1 [k, , k].

4.3.4.3.


, , , , . : .

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

, , .

: a+b*c-d/(a+b)

: abc*+dab+/-

, 2 ( ). . , .

rj . r1 r2 , . . 2. .

.

2 , , , , . , rj, ,

2

1 2 3 4
1

a bc*+dab+/-

-
2

a b c*+dab+/-

-
3

ab c *+dab+/-

-
4

abc * +dab+/-

r1=b*c

* b c r1

5

ar1 + dab+/-

r1=a+ r1

+ a r1 r1

6

r1 d ab+/-

-
7

r1d a b+/-

-
8

r1da b +/-

-
9

r1dab + /-

r2=a+b

+ a b r2

10

r1dr2 / -

r2= d/r2

/ d r2 r2

11

r1 r2 -

r1 =r1 r2

- r1 r2 r1

12

rl

- -

, . , . , , , , . .

. , , ( ). R k (k1). . , , , . , .

() i. , i=1. , j=1.

.

1. S .

2. S , S [i] , i=i+1 1, 3.

3. S , 4, , S R,

    1. [i-k], k R, l. , l=j.

    2. , rl=R([i-k],,[i-1]). R(x1, , xk) R x1, , xk.

    3. rl [i-k].

    4. : i=i-k+1 j=l+1. 1.

  1. , . rl, .


























.4. - .


3.2. , , . , R.

, , , , R, . , , . 3.2. . , , , , . .

- 4.

, , , , .


4.3.5.


, , - . :

struct Blocks

{

int type; //

int x; // X

int y; // Y

int true_x; //

int true_y; // (TRUE)

int false_x; //

int false_y; // (FALSE)

char* text; //

struct Blocks far *next; //

};


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

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

. , , .

. () . . , .

. , , .

. , . . , , .

\ . , () . , . , ( [ , ] ) , , . , .

.

, , (). , .

“.”

: , , , , (true), (false).


4.4.

4.4.1.


, , . , , , , -, , , .

“ ” . ( ) . , Borland, MS-Dos, Windows MS Windows 95. , “ ”, . sch MS-Dos scw - Windows.

:

struct FILE_SCHEME

{

int type; //

int x; // X

int y; // Y

int true_x; //

int true_y; // (TRUE)

int false_x; //

int false_y; // (FALSE)

};

, .

. type , . x,y . true_x, true_y . , false_x, false_y - . NULL, .

. , .

Windows , - .


4.4.2.

4.4.2.1. MS-Dos


, , . MS-DOS 3.0 Windows 3.1 . MAIN_CURS.EXE, . , . , .


:

, - , , .

-. -, .

.

, , .

.

“ ”, -, , , .

“” “” , , . ( -) , .



, . , . .

, “” , “”. , , , . , , .



:



, ( ). :



. :



“” : .


4.4.2.2. Windows


Windows, “-.exe”. .



:

, - , , .

-. - -, , .

.

, , .

.

.

.

, -, , . .


“ ” , .



:



  • ;

  • ;

  • ;

  • ;

  • ;

  • .

, “”.

, “” , “”. , , , . , , -.



"" :

  • ;

  • ;

  • ;

  • ;

  • .

.

,


, . ,


:



, “ ” . . :


  • ;

  • ;

  • ;

  • ;

  • .


, :



“” . “” . “” .

, , “” “ ”. :



. , .

“” “” : .


4.5.


, “ ”.

- :

struct BLOCK

{

unsigned int type; //

int x; // x

int y; // y

char *text; //

int true_x; // x

int true_y; // y

int false_x; // x

int false_y; // y

struct BLOCK *next; //

bool StopRun; //

bool ErrorFlag; //

bool RunBlock; //

struct SVERTKA* Poliz; //

};

:

struct BLOCK

{

unsigned int type; //

int x; // x

int y; // y

char *text; //

int true_x; // x

int true_y; // y

int false_x; // x

int false_y; // y

};

: :

struct VARIABLE

{

AnsiString Hint; //

char* name; //

char type; //

unsigned int Size; // , Size == 0,

//

unsigned int* SizeN;// ,

// SizeN == NULL

char* ready; //

int* __int; // int

long int* __long_int;// long int

char* __char; // char

float* __float; // float

double* __double; // double

struct VARIABLE* next;//

//

};

:

struct CONSTANTA

{

unsigned char type; //

int __long_int; // long int

int __int; // int

char __char; // char

float __float; // float

double __double; // double

char* __string; // string

struct CONSTANTA* next;//

};

, , . , :

struct SVERTKA

{

unsigned char type; //

unsigned char intype; // ( , ,

// )

struct VARIABLE* variable;// variable==NULL

//

// variable == NULL

struct CONSTANTA* constanta;//

// constanta==NULL

//

// constanta == NULL

struct SVERTKA* next; //

int result; //

};


.

, -, , , .

. :

  • MS-Dos,

  • Windows NT, Windows 95, Windows 98.

MS-Dos 300 , Windows 900 .

6 - “ ”, 17 19 1999 . ( ).

. .


  1. .. . - : , 1975.-315.

  2. . , - : , 1975.-544.

  3. .. , .. .- : , 1986. -343.

  4. ., . , 2- . - : , 1978.

  5. .. -. // - “ ”. - : , 1999.-227.

  6. .., .. -. // - “ ” : , 1999.-227.

  7. .. “” // . 1995. - 3.

  8. .. -. - : “ ”, 1995.

  9. , Borland C++Builder. - : “ ”, 1998.-704.

  10. Lee C.Y. An algorithm for path connetion and its applications. // “IRE Trans.”, V.EC-10 - 3.

1: -


MS-Dos :



Windows :



1. .


2. (Windows ).



3. (MS-Dos )

2:


()



0 ( ) + - / *

<

> = ^ | ! [ ] , ; & . 0 ‘’
0 1 2 22 22 9 12 14 15 17 24 14 18 23 22 22 22 22 22 3 -9 E 0 4 6
1 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 -1 -1 -1 0 -1 -1
2 -1 2 -1 0 0 0 0 0 0 0 0 0 0 -1 0 0 0 0 3 -1 -1 0 -1 -1
3 -1 3 -1 0 0 0 0 0 0 0 0 0 0 -1 0 0 0 0 -1 -1 -1 0 -1 -1
4 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5 5
5 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 7 -1
6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 6 -1 6 6 8
7 -1 -1 -1 0 0 0 0 0 0 0 0 0 0 0 -1 0 -1 0 0 -1 -1 0 -1 -1
8 -1 -1 -1 0 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 0 0 -1 -1 -1 -1 0 -1
9 0 0 0 -1 10 -1 -1 -1 -1 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 0 -1 -1 0 -1
10 -1 -1 -1 0 -1 -1 0 0 0 0 -1 0 0 0 -1 0 0 0 0 -1 -1 -1 0 -1
11 0 0 0 -1 -1 0 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 0 -1 -1 0 0
12 0 0 0 -1 -1 13 -1 -1 -1 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 0 -1 -1 0 0
13 -1 -1 -1 -1 0 -1 0 0 0 0 -1 0 0 0 -1 0 0 0 0 -1 -1 -1 0 -1
14 0 0 0 -1 -1 -1 -1 -1 -1 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 0 -1 -1 0 0
15 0 0 0 -1 -1 0 -1 -1 16 0 11 -1 -1 -1 -1 -1 -1 -1 -1 0 -1 -1 0 0
16 0 0 0 -1 -1 -1 -1 -1 -1 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 -1 0 -1
17 0 0 0 -1 -1 0 -1 -1 -1 16 11 -1 -1 -1 -1 -1 -1 -1 -1 0 -1 -1 0 0
18 0 0 0 -1 -1 0 -1 -1 -1 -1 11 -1 19 -1 -1 -1 -1 -1 -1 0 -1 -1 0 0
19 0 0 0 -1 -1 0 -1 -1 -1 -1 -1 -1 -1 0 -1 -1 -1 -1 -1 0 -1 -1 0 0
20 0 0 0 -1 -1 -1 -1 -1 -1 -1 11 -1 -1 0 -1 -1 -1 -1 21 0 -1 -1 0 0
21 0 0 0 -1 -1 0 -1 -1 -1 -1 -1 -1 -1 0 -1 -1 -1 -1 -1 0 -1 -1 0 0
22 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
23 0 0 0 -1 -1 -1 -1 -1 -1 -1 11 -1 -1 0 -1 -1 -1 -1 -1 0 -1 -1 0 0
24 0 0 0 -1 -1 0 -1 -1 -1 -1 11 -1 -1 -1 -1 -1 -1 -1 -1 0 -1 -1 0 0

“”


Int

Long

Char

Float

Double

,

;

[

]

NULL

0 -30 -31 2 1 2 2 2 -32 -32 -32 -32 -32
1 -30 -31 2 -30 -30 -30 -30 -32 -32 -32 -32 -32 -32
2 3 -33 -33 -33 -33 -33 -33 -32 -32 -32 -32 -32 -32
3 -32 -32 -32 -32 -32 -32 -32 2 0 4 -32 -32 -32
4 -34 5 -34 -34 -34 -34 -34 -34 -34 -34 -34 -34 -34
5 -34 -34 -34 -34 -34 -34 -34 4 -34 -34 6 -34 -34
6 -34 -34 -34 -34 -34 -34 -34 2 0 -34 -34 -34 -34

“”


[

,

;

NULL

0 1 -35 -35 -35 -35 -35
1 -35 1 \ 0 \-36 0 2 -35 -35
2 1 -35 -35 -35 -35

1


.

[

]

,

+

-

~

#

*

/

^

Mod

Div

(

)

NULL

0 1 . 2 . . . . . 4 4 . . . . . 1\1 . . .
1 . . . 2\0 . . 3 3 . . 3 3 3 3 3 . . .
2 . . . . . . 3 3 . . 3 3 3 3 3 . . .
3 1 . 2 . . . . . . . . . . . . 1\1 . . .
4 1 . 2 . . . . . . . . . . . . 1\1 . . .

2


.

[

]

,

+

-

~

#

*

/

^

Mod

Div

(

)

NULL

0 1 . 2 . . . . . 4 4 . . . . . 1\1 . . .
1 . . . 2\0 0 3 3 . . 3 3 3 3 3 . . . .
2 . . . . 0 3 3 . . 3 3 3 3 3 . . . .
3 1 . 2 . . . . . . . . . . . . 5\1 . . .
4 1 . 2 . . . . . . . . . . . . 5\1 . . .
5 . . . . 0 3 3 . . 3 3 3 3 3 5\1 . . .

strlen


-

[

)

NULL

(

0 . . . . . 2 .
1 . 3 \ 0 . . . .
2 1 . . . . . 4
3 . . . . . .
4 . . . . . .

“”


str

1

2

5

Clock

Strlen

,

(

[

;

NULL

)

0 1 2 5 . 4 6 2\2 . 2\3 . . 9 . . .
1 . . . . . . . 0 . . 10 . . . .
2 . . . 3 . . . 0 . . 10 . . . .
3 . 2 . . 4 6 2\2 . 2\3 . . 9 . . .
4 . . . . . . . . 2\3 . 10 . . . .
5 . 2 . . 4 6 2\2 . 2\3 . . 9 . . .
6 . . . . . . . . 7 . . . . . .
7 . . . . . . . . . . . . . . 8
8 . . . 3 . . . 0 . . 10 . . . .
9 . . . 3 . . . 0 . 2\0 10 . . . .
10 1 2 5 . 4 6 2\2 . 2\3 . . 9 . .

“ ”


str

.

(

[

;

1

2

3

5

Clock

Getch

Kbhit

Strlen

)

NULL

0 . . 1 . . . . . . . . . . . . . .
1 . . . 2\0 . . . 3 . . . . . . . . .
2 . . . . . . . 3 . . . . . . . . .
3 . 4 5 4\3 . . 6 . . 8 13 10 13 4\2 . . .
4 . . . . . 9 . 7 . . . . . . . . .
5 . . . . 4\0 9 . 7 . . . . . . . . .
6 . 4 5 4\3 . . . . . 8 13 . 13 4\2 . . .
7 . 4 5 4\3 . . . . . 8 13 . 13 4\2 . . .
8 . . . 4\3 . . . . . . . . . . . . .
9 . . 1 . . . . . . . . . . . . .
10 . . . 11 . . . . . . . . . . . . .
11 . . . . . . . . . . . . . . 12 . .
12 . . . . . 9 . . . . . . . . . . .
13 . . . 14 . . . . . . . . . . . . .
14 . . . . . . . . . . . . . . 4 . .


str

1

2

5

Clock

Strlen

(

[

)

NULL

0 1 . 3 4 . 5 6 3\2 3\3 . . . .
1 . . . . 2 . . . . 3\0 . .
2 1 . 3 . . 5 6 3\2 3\3 . . . .
3 . . . . 2 . . . . . . .
4 1 . 3 . . 5 6 3\2 3\3 . . . .
5 . . . . . . . . 3\3 . . . .
6 . . . . . . . . 7 . . . .
7 . . . . . . . . . . 3 . .

“”


str

[

;

,

2

Programm

NULL

0 . 1 . . . . 4 . .
1 . . 2 \ 0 . . 3 . . .
2 . . . . . 3 . . .
3 . . . . . . 4 . .
4 6 5 . . . . . . .
5 . . . . 4 . . . .
6 . . . 7 . . . . .
7 . . . . . . . .

“” “ ”


;

NULL

0 1 . . .
1 . 2 . .
2 . . .

“ ”


str

(

[

!

4

;

NULL

0 . 1 2 3 \ 4 . 4 . . . .
1 . . . . . . 5 6 . .
2 . . . . 3 \ 0 . 5 6 . .
3 . . . . . . 5 6 . .
4 . . 2 . . . . . . .
5 . 1 2 1 \ 4 . 4 . . . .
6 . . . . . . . . .

“ ”


str

(

[

!

4

)

NULL

0 . 1 2 3 \ 4 . 4 . . . .
1 . . . . . . 5 . .
2 . . . . 3 \ 0 . 5 . .
3 . . . . . . 5 . .
4 . . 2 . . . . . . .
5 . 1 2 1 \ 4 . 4 . . . .

“”


true

false

;

NULL

0 1 1 . .
1 . . 2 . .
2 . . . .

“”


;

NULL

0 1 . . .
1 . 2 . .
2 . . .

“”


Return

;

(

NULL

0 1 . . . .
1 . 3 2 \ 3 . .
2 . 3 . . .
3 . . . .

3:


- :


ClassScheme ( )

,

Basic Block for Windows 95 ver. 2.0.

Copyright(c) by .., 1998 ., , ,


#ifndef __CLASS_SCHEME

#define __CLASS_SCHEME


#ifndef __STRUCT_FILE

#include "struct.h"

#endif


//


#include

#include

#include

#include


//


#define BEGIN_BLOCK 0//

#define END_BLOCK 1//

#define IF_BLOCK 2//

#define INPUT_BLOCK 3//

#define OUTPUT_BLOCK 4//

#define PP_BLOCK 5//

#define AD_BLOCK 6//

#define LABEL_BLOCK 7//

#define BP_BLOCK 8//

#define MULTI_BLOCK 9//

#define VETV_BLOCK 10//

#define UP_BLOCK 11//

#define DOWN_BLOCK 12//

#define UP_RIGHT_BLOCK 13//

#define UP_LEFT_BLOCK 14//

#define DOWN_LEFT_BLOCK 15//

#define DOWN_RIGHT_BLOCK 16//

#define LEFT_BLOCK 17//

#define RIGHT_BLOCK 18//

#define RIGHT_UP_BLOCK 19//

#define LEFT_UP_BLOCK 20//

#define LEFT_DOWN_BLOCK 21//

#define RIGHT_DOWN_BLOCK 22//


//


class ClassScheme

{

public:

bool TypeOfProgramm;// (==true)

char *FileNameScheme;//

struct BLOCK* HeapBlock;//

struct SVERTKA* SvertkaBlock;//

struct BLOCK* Buffer;//

struct VARIABLE* HeapVariable;//

struct CONSTANTA* HeapConst;//

struct Rects RectPl;//

struct CONSTANTA* MultiConst;//

bool FlagRun;//


//


int Poisk_Function(char *,int ,char* []);// //Ok

void DeleteVariable(struct VARIABLE* );// //Ok

void DeleteSvertka(struct SVERTKA*);// //Ok

void DeleteConst(struct CONSTANTA* );// //Ok

int ClassSimbol(const char&);// //Ok

int LenTextBlock(char*);// // Ok

void DeleteScheme(struct BLOCK*); // // Ok

void CopyStrToStr(char *,char *); // //Ok

int AddStringToTextBlock(struct BLOCK *,char *);//

// //Ok

void GetsStringFromFile(FILE *,char *);// //Ok


//


ClassScheme();


//


unsigned char LoadFromFile(char *);//

// //Ok

unsigned char SaveToFile(char *); //

// // Ok


// -


struct VARIABLE* PoiskVar(char* );// //Ok

struct VARIABLE* CreateVar(char*, char,unsigned int,unsigned int*,int);

// //Ok

struct CONSTANTA* CreateConst(unsigned char,char*);// //Ok

unsigned char TextBlockToSvertka(char *, int);//

// //Ok

int ClassSvertka(struct SVERTKA* ,int [][2],int ,int ,int );// c //Ok

void UnarOperation(struct SVERTKA*);//

// n-(+,-)//Ok

struct SVERTKA* Insetr(struct SVERTKA* ,unsigned char);//

// ';' //Ok

unsigned char Sintacsis(struct SVERTKA*,int [][2],int,int,int,int*,

int*);// //Ok

struct SVERTKA* SintacsisHelp(struct SVERTKA*,int [][2],int,int,int,

int*,int*);// //Ok

struct SVERTKA* Polis(struct SVERTKA*);// //Ok

struct SVERTKA* Stek(struct SVERTKA* ,int);//

// //Ok

struct SVERTKA* Run(unsigned char,int&,struct SVERTKA*,int,

struct SVERTKA*);//

//

unsigned char Run(struct SVERTKA* );//

// //Ok

unsigned char RunBegin(struct SVERTKA*);// //Ok

unsigned char Translation1(void);// //Ok

unsigned char Translation2(void);// //Ok

unsigned char Translation3(void);//

struct BLOCK* BpFunction(struct BLOCK*);// //Ok

float Trigonometria(struct SVERTKA*,int&);

// //Ok

struct SVERTKA* NewSvertka(int&,unsigned char,unsigned char);

// //Ok


//


struct BLOCK *Poisk(struct BLOCK *);// //Ok

struct BLOCK *Poisk(int,int);// //Ok

struct BLOCK *Poisk(unsigned int);// //Ok


// , ,


void Add(struct BLOCK*);// //Ok

struct BLOCK *Create(unsigned int,int,int,int,int,int,int,char *);

// //Ok

struct BLOCK* Cut(struct BLOCK* );// //Ok

void DelBlock(struct BLOCK* );// //Ok

void DelBlock(int ,int );// //Ok


//


void CopyBuffer(struct BLOCK*);//

// //Ok

void CopyBuffer(int x,int y);//

// //Ok

void CutBuffer(struct BLOCK*);//

// //Ok

void CutBuffer(int x, int y);//

// //Ok

void PasteFromBuffer(int, int);// x,y/Ok


// ()


void SizeOfPlanhet( void );//Ok


//


void AddNumber(int*,int,int,int,int,int);// //Ok

int Maximum(int*,int,int,int,int);// //Ok

float Rastoanie(int,int,int,int);// //Ok

void Index(int*,int,int,int,int,int,int,int,int &,int &);//

////Ok

bool Algoritm(int*,int,int,int,int,int,int);////Ok

int* MatrLee( int&,int&,int,int,int,int);// //Ok

bool StartLee(int,int,int,int);// //Ok


//


~ClassScheme();

};

#endif


:


- Basic Block for Windows 95 ver 2.0.

Copyright(c) 1998, .. 1998/1999 .


#ifndef __STRUCT_FILE

#define __STRUCT_FILE


struct NameOfVar

{

char* name;

struct NameOfVar* next;

};

struct Rects

{

int Left;

int Top;

int Right;

int Bottom;

};


struct BLOCK

{

unsigned int type; //

int x; // x

int y; // y

char *text; //

int true_x; // x

int true_y; // y

int false_x;// x

int false_y;// y

struct BLOCK *next; //

bool StopRun;//

bool ErrorFlag;//

bool RunBlock;//

struct SVERTKA* Poliz;//

};


struct VARIABLE

{

AnsiString Hint; //

char* name; //

char type; //

unsigned int Size; // Size == 0,

//

unsigned int* SizeN; // ,

// SizeN == NULL

char* ready; //

int* __int; // int

long int* __long_int; // long int

char* __char; // char

float* __float; // float

double* __double; // double

struct VARIABLE* next;//

//

};


struct CONSTANTA

{

unsigned char type;//

int __long_int; // long int

int __int; // int

char __char; // char

float __float; // float

double __double; // double

char* __string; // string

struct CONSTANTA* next;//

};


struct SVERTKA

{

unsigned char type; //

unsigned char intype; // ( , ,

// )

struct VARIABLE* variable;// variable==NULL

//

// variable == NULL

struct CONSTANTA* constanta;//

// constanta==NULL

//

// constanta == NULL

struct SVERTKA* next; //

int result; //

};


#endif



. , ... _______________ .. &ldquo;____ &rdquo; ________________ 199

 

 

 

! , , , .
. , :