WWW.IRANMEET.COM

Programming Languages Design and Implementation, 4Edition

( ) *!)

%$&

'

$ ! " #

!, -

+ ./ +& 1

2

..0 /# 86 5&

[email protected]

/

WWW.IRANMEET.COM

. / 01 $ 23 * 4

/ ( )" & 3

!" #$% % 1& 4

!-

'%

"< " #6 " )

*% B 9C !+-4 "

D E ,

&-

' % >" )"

(""- ?

"#

"-

1& 2 %"

@3 " ) *

4

-

( 3

9

"- 9 . ) # )-

=

)* 7-

4

F G )"

.ILispH# 3 , "&-4 9 C++ + C :

%

$ '

1 D /&&-

1& 2 %" ) " - #*% B

- P

/& 7 3 #

. "+ )

NAO

/& 3

1& 2 %" #T L

B + Q"

%& ; ) U : InemanicH /&

) )

& ) -%

+-W :-

#

+, - & U : & RS" ? B 9 )& 9U - Q S 3 c 9?

&<) $ *M

# +

1& 2 %" & D Q *% B

9IALGOLH? !" 9? % 4

(

3"& 7 3 "- #

/ )

R* %"

--

& :+ #

#

! #+

"+"

K

8 9: 4 6

& D Q *% B

!"

# !

" -

#3

:#

) 97 3 # & # . "+ - 1+VD

( )*&

'&

# :- U : :-

NJY !" NJJ -X%+-4 + M-3 Q"

#

?% & %& 9 #ZRL / )" #)

[email protected]

J

N=O # & -'"+" "

RS" Q S E' " / & $ %"&

.%

L"-M

2&'6 7

" D# -

A

- &

:

7 " &-

0

# )- 7 3 ) & 3

2

/ ?"+ 9 --

. ) # )-

; "< "

#6 # 7 " 9 . ) # )-

5

& & ' ( )" & * + ,- .

5 + #) 6 # 7 " 8 & 9& : /

&

)

7" 7" &X" (

'%

7 " " 1- [ +

WWW.IRANMEET.COM

( )*& $ / .

4 ;5

7 " #R : " Visual c 9 VB

+ + UB

/<08 ! +

UML

&

$= D 7 Iplat formH

I/// +

%& 9 $ 9 ("I /// +

I#T L

-% U 4 + U \

] + Link list " V 9& 3 1& 2 %"

%?

#6 " # "

8 4! K'

'L

D . % + "< " UG% @3H

T) 9

% # )-

,+

0

X 9 $ SH &-

% 1& 4 "- V H

% 1& 4

=

,+

A

@ Q $! ^

J

% & " ) %"

K

M' / /U3"&

" ' -

/U3"& /U%" -

L"+

/U%" -

% # )% # )-

9 3 # )- 7

1& 2 %" Lisp U%" % # )-

% # )3 -.

!' 0 =

"

+

" ' -

#3

9& 3 e X)" -

Syntax

& -

_ W+ 3 _ W+ #6 - c

"- V c! 4 1 b d"<:"

Debugger9 Linker9-R

P

+B C %*6

#Z*M #6 - c - T)

$>! & #?'@

&% 3 -

#2! #6 %

b IAbstrationH>"< )" "< + 3 - `G

9 3 -

$>N

2 8 & #6 "<:" 7 a * " : 'A 4! ?'@

Syntax

! 41

!' $2 %D

=

<6 $ % +B8

A

!!

E6 $>! &

J

&

FA

Support for abstraction

% # )- f B Q )

" #6 -

0

K

/U%" UL"

- &I

D . %H "< " UG% # I

D . %H "< " UG% " ? Z )" #6 -

G8

Portability

/U%" -

% # )I! +& 0 J

H+

Y

& 3 e X)" !'

8

Disk9 RAM9 CPU

S EG - P

h

" 1& 2 %"

3 # )-

Disk9 RAM9 CPU

S EG - P

h

" 1& 2 %"

3 # )- # :- # <

/ ) .)" +- ) + - P

h

[email protected]

" 1& 2 %"

"-:" # <

3 # )- U. + & X " # <

g

WWW.IRANMEET.COM

/Qi 3" &- j-M - + "< " e-) & + &- k -

"

:Q)

" mR G / -

" & X " 9 ^ B k)" : # )- l *^ # <

5+ "

-T) & " -

# U%" 7 "

M-3

/ &-

%& +

T

*% B

%&

$ 9

4# <

26 - O

Orthogonality

*% B Q *D V 9 3

%& & "

If

$ "

3 )*

$

<) SLk -

$

If (a+b>c+d) then …

! 41 P "- '" C++ + C + # 3n & ? " # %& 7 " / 3

/// + -R P

% 1& 4 +

PL/1

9 R* %"

D

. % 7 3 ) "- 9

3

U.4 #

"-:" F+ UB -

& ' Sb

" - n!" p

"

I

"- H

*

+ ) 3

4#

- .2 # R ) 3

# )-

U!$ #

9

?-

)

"-

@3H8 " %" + > )

"@

%-

RD

&-

0

.%

&-

=

D E ,

P H P - %"

" - & # )- # "

"-

% # )-

1 fB

L"-M & &

) EZ f B U%" 7

-\

4"

#

R D f B 9I "< " UG% +

EZ f B /& "& e )

" 1 3" &-

)*

D

9

< fB & 3

"< " UG% 9& 3 H

Q S ) & "< " e-) "-:" + #$% #

J

T 9

)+- !"

9

:

&-

K

2&'6 +

R6

) e X)" dV' & "< " e-) #$% )*

("& ? 3" + U. 9

A

"-:" + # :- 9# ' 3

Q Z ZB & ML

.%

&-

" # )- o D - 9& 3

4 J, f B 9& "&

%&

"-

> ) 7 " # /// + UD % Perl

IqB

)

# a * " & X " + "< " UG% # C !+-4

"-:" f' # f'9I ) 3

Q'

X , "&-4 --

# &b

N

4 " # )-

9 L"-M

f B 7 " " #) ) 6 # -

"-:" #

& # )- #

: ' ^ B /& 3

& 9 3 Q+ 2

< /

+&! F A 1&"& 9# bach

&+ + " D # " 1&"&

H " # %& , "&-4 "

7" & 9 ) 3

R D fB 7" /

!

, "&-4 " # %& Q S # + ) 3

r /& 3 "-:" /

" " #D X # )- /U% 1&"&

) #( " # )-

M#

"

:+-' 1&"& # %&

# )- 9 ^' , "&-4 " o4 "- 91& *) ? *b

"-:" UD-% + - "

-\ r fB 7" &#

[email protected]

"

R D f B 7 - 1& % "

" #D X + , "&-4 "

)

& &+ + Q DVM" "- /

Iprocessing

b

( ^' f B

& # ' " # )#

+ & " ) & :+ -

"-:" # "-

WWW.IRANMEET.COM

I4 A F A .% "

f B #)

# # k - 7" U%"-:" 1& -*

#

7 " /&

9

)-

1& 2 %" & 3 #

) & :+-' + & "&

1&"& - P

- & # )- # 1 ) "&-4 9

)fB 7" & #

" # )- )"

1&"&

# L"+

$ & # mR G

,- 7 " e " " $ 9& 3

+ U%" "& ' -

^' +- Q S & + 1& - P

U 4

/U. ) ? *b

-

Z . # )-

U

online

e X)" "-

1&"& ITime SliceH )

. % 7 " # U%" ,"- 7 3

- n4 ) "-*: Q ^! + U. ) ? *b

b

4"

"-' (

Q S# -

"- 9& " )

b

8"- 3"

,-

# )- -

C<

.%

"

G

f B > ) 7 " RS"

s BE + %26

- P

#EG

1&"&

^' , "&-4 7 3"& #

b ^' +- Q S & # )- # ' "

. % 7 6 7 " & /& "& 1 D # " C <

/&- 1 3" - & " # "

)

" " " 1 + B f B & ^' , "&-4 /& 3

Iembeded systemHI #2 t+ - P

fB 7" &

/+ & F A

.%

fB 7" &

.% "

" &&-

%&

G

?-

& "+ C <

.%#

cIReliabilityHUBS + & D" U R b 1 %& + + &+ +

! $ fB

+ + #M -

D .% + i $

1 %& a * " "- v EG

#+

# )- " e"

f B #)

- u D & /& 3

/& "&-4 /& % j-M - ,& ' '"& & "

^' )"

# )- - U%"

) #

L+ /U%" ? *b

C<

.% " #

S ' &+ + "-

- P

. % x% 4

7 " "- 1 3 # 3 )

$

/

U .b 7 6 " + D

.

b - [ 9#$: hb"

&-

& )

. ) L"+ - P ?-

. % :+-'

f B 7 " & ^' , "&-4

w) & V

M# +

:+-' + &+ +

$ # + & "& C <

/ 3 1 3 7 ] `G " & ' v ' #2 t+ U .b - 9U%" 1 3

"-:"

# )-

1

# )- # '

.% > ) 7" &

U%" # -

.%> )7"i $

" C<

.% "

G e"

- + & "&

IDisturbutedH$2 '6 f B / 3 # 3"& I +& 1" /&&-

"-:"

"H Remote Q S # "-:" U R b # U%" ( # )- U % # ; "- - '" Remote

Q S#

) &

# )- #

.

f B 7 " #R : " RB

imperative

[email protected]

FA ?% &

# *3 + F+

4'+&!

WWW.IRANMEET.COM

Q *\ " Z

CPU

%& 0

:-

& 3

k:

/U%" - Q S #

(

%& -

"-:" + U%" Q"

7 6 B) /&-*

%& "

#! *)&

: U! L # " 7 3

3 # )-

7" &

$ / & - y " #T L " RB

%& /& 3

)*

4 Ada+ C++ 9C

(

&1

$2 6

functional

&" & :

1&"& # 7 "

:#

$ /& 3

F R^ #X ) &+ + 1&"& + - Q R D 1&"& 7 "

& 3

e X)" 1 z 4 h " 7 ' %

/U%" - Q S #

? *)& # )- &- R D 7 3 U! L - y &- ? *)&

"-b - Q S & T #

$ 9U3"&

R*b 1 3 & X " h "

7 " B) /

) ! # !+"

: # ,+ 7 " &

" ' -T) & " F R^ #X ) 9 -

1&"& " " x% 4 h 7 -' + 1&.

/&-

Q S

/U%" - Q S # a-3 &" $ 0 a-3

&" $

n a-3

&" $

(

! $ 9f "-3

&

7 6 B) /& 3

"-b - Q S & + & 3 1

) < ) Z^

+&

ML

+ Lisp

0" ' O

%-

. ) # )-

SL %& " # !+"

$

rule based

7 - ?+"

-T)

" $ " & X " # )- #$% /& 3

f n (...( f 2 ( f 1 (data )))...)

)b

&7"

^ "-3 #

3

7" & prolog

Q R D e X)" 0 Q R D e X)"

n Q R D e X)" object oriented

d 3" " v ' 1&

1

&

) {V - / 3

{V 7 " + " 1 3 # ' %

C++. 9 java

"

*D ?

7 " " #) ) ) "&

3" +

S > $T {V

7 " { %"

+

S E' # U%"

#

6' X 1

Y "L 4 + & DataVU3

/

"- Q R D e X)" "- " #

' % + # !+"

1&"& " " #D X

- P

primitive operationVM I7 3

CPU

Q"

%& ) H 3 # 3"& - & "

1& "& + Q R D "- # !+" Q R D " " # D

X

- P

Data ControlVW

& %

"- Q"

%& "-:" ?-

U : ( e< )

- P

Storage managementV!

[email protected]

WWW.IRANMEET.COM

/ 3 # 3"& #T L

% &" 7 z

+ 1&"& + # )-

"- #T L ` EG U : ( e < )

-

P

operating environmentV

& %

"-

*) :

1 %& Q DVM" #!& *

"-

( <)

- P 6 'X 1 Q'

"< " UG% Z b& /U%" 1 3 # ' %

)- !" Q" "

+

"< " UG% d"<:" " V

Harware "< " UG% - P

# U%" - P /& "& & :+ 7 3

#T L & # U%"

Micro operation

" " #! *)& 7 3

%& - # a -

Firmware # ' % Firmware Q S # - P

%& - # & 3

ROMH

.U%" 1 3 1- '| IPROM ! 1 "L

I4 !

$R C D

< # )-

'6 $ ( )*&

b

& I! 8 c ITranslationH " 6

U%" "< " UG% + "-:" i s^%

b# & 3

73

#

*

(

"-

:-

# " * # )-

M i s^%

#

I R* %"H7 3

" # )- ,+ 7 " &

# EZ # )-

^L e y 4

-& /& 3 "-:" "< " UG% + - )" / &

& " ) %" Q S #

"-:"

:+-' + i s^%

R 3 # # )- ? Z )" "- U%"

e X)" " 7 3

/ /& %

#

#

R* %"

"-b RAM #T L & " "-:"

b " # ) - + 1&-

E -

# )-

&+ + # U%"

U%" C

& Include

Y4'

v'?

"< " c

0

b # )- c I 001 4 4!'3 = T

U .b Linker A I

/U%"

c Isoftware simulationH 4 J,

[email protected]

X 1

" # )- ? Z )" c %"&

# " # ) - mR G Preprocessore "

/ + Q'

! 8 78 J #

( & %

WWW.IRANMEET.COM

s^%

%& simulator + /IU%" "< " e-) /

#

!L && 3 "-:"

%&

"-:" oP% + 1 3 % # *3 "- e i Q"

simulatorH&

"-:" " i s^% * 73

#

3

1&"&

simulator#

Z . # )-

%& e X)" "- e i Q" # )- ?+" ,+

& # U%"

%& #D X oP% + - .2 " " i s^%

Q"

Source

e< )

7" &

%& #D X + - .2 " i & ,+ +& 7 " Q+ 2 %&

e+& ,+ & /&&-

[email protected]

WWW.IRANMEET.COM

* 1

" '

2

!" #$"

,3 4

&"

virtual computer

*

9 :

,

4 )( ) % 3 0 % 12 " % ! 0 % 12 " % # os ! .( )%

#

%( $

"%

)

"% & '

" & '

&" '()

- ./,

; : 8,

. ( ) % % * + ,') ! "

/

$ !

+ , '()

% 0"

5,

"

%

*56 7

# #

# %(

!

#

< $< = !

HTML

'" 6 = D

HTML

*

> )

5,

*

'()

F 0" > +K

" "? 3 4

1

&"

< Lisp

5,

<

C" 8 B

F Prolog

%

'D

B >

)

*5,

&"

L<

@ >

)

F

%

, AB

8 B &"

&" C"

F

> G , 5" , F

BG4 &" > ?

I

&"

5 4 N+ &" 9

> +K $<

6

J

C

Binding

&" ?

E4

>

N ) &" - ./,

. B4 O &" HD * " 7 Binding time

@)

3 )H: I

Binding

( M + ) (%

%

Binding

* C

+

,> J C< '() " (

C


+ ) (%

Binding

*5, "

'

>

Q@: '() "

%

2 9

Binding

SRun timeR * *5, < Binding 3 U

4+

% VW

[email protected]

" " TH %

Binding

P &"

/Q <

P

WWW.IRANMEET.COM

STranslation or compile timeR ( 8,

+,

X? P

# < O E" ! = D

)

#0"

8, >

= () "

>

* 4+

< 'B

< O #

=D

load

)

# Translator 8, >

FY

ZY[ 0"

= () " >

FY

* FY

"

( 5] 9

)

"

3(

^ " 3 @, B #3 () # ) \" ( = D

! 'D *

ZY

E" !

C<

*

]

Q

?

d5

* Se

Q R5

< +

"?

"

"bJ _ /!

< + > (< $

U

$ 5) , ]

"bJ _ /!

fO

5) ,

f

]

"

<

"

> "

HD

"

Q

!"

ZY[

<

< Q

E" ! *

"

S= , J

( P 'D R= , J

C

'D

'D <

+

ZY[

*

xP #x

H) "

O &"

P &"

&"

Float

P

5 >c

Q &" 7 HD *

5, 3 @) x

W 7

= ,J

# L<5

P

HD *

!

"

Bind #

( " Q

,> J x

4+

'() " R Q

5

[email protected]

" ` 6 8Q6 = , J

<

+ ) (% 3 4

- (! x & ( x>

x 5,

x

,

P >

5,

x

#

" !

ZY[ (

,> J

) *

"

( P

( W

!

> G, ']

#

%$<

ZY[

" Q ) (% S5, *

"

. B4 P

! <5

,

) (% : x

' ] &"

'

L

< + ZY[ (

:

Q C"

, ,'

5, >

E" !

"

Q F

*

!

1

'

5,

Bool# set # character# integer # real

*

'() " 7 '() " 7

<

= @W ' W P

> G , ***

9

SType convesionR3 )H: P '" @

3 4 " x

% "

(

I,J

Binding

" 5 !W

0/ ,- . (' ( x=x+10 +

*

"bJ _ /!

&" Type 7

+, D

fortran

5) ,

9 *5,

< int P

"bJ _ /!

)

E" !

, *

* " 7e "

16 9

,> J

Slanguage definition timeR _ 9 C" = D

Binding

Bind

SLanguage implementation timeR

*

Binding

P a ] J & ] (,

( <

#

%$P

' QW

6 7 1 /Q <

"

*

" ! ) (% b] * . B4 P x & (

7 O

WWW.IRANMEET.COM

*

%

E" !

S3'

)

ghR

*

%

!"

'+

,> J

< < \" ( F Y

# + \" (

10

<5

1# 2 ( FY

]9

i C () * ZY[ <

() P >

ZY[

S *** "

%

E" !

0JR

< V( #

V( '() \" (

ZY[ (

V(

i ( FY

%

[) V( #. B4 V( # <

i C ()

%

!(

j i 5 H)

S' !

2,

3 () #E Y

P

>

&"

M + ( &"

P

> G,

* *

% i 8, > G , *** "

() j

ZY[ '"

[) " . B4 V( '()

V( '() <

V( M + '() &"

Bind

E" ! i (

* Q # _ /!

ZY[ ]

"

9

"

8Q6 ?

, Q '() 7 # &" Type 7

U

<

Q 2

Lisp

ML'D

L<

()

* 7

L<

'

,> J

V( '() <

' ] &" *Se

"

7

"?

3 4 (

<

[email protected]

) (% Q #

Q 2

Bind

Q [

G7 e

"

$

"bJ

QR "

Fortran

* 7

67

7?

V( '() < 3 Lc

'() " 7 "

? <

"bJ _ /!

- (! R 5, ?

%

6

i #= , J 'D

5) ,

* <

,> J

) (%

"

<

M + > G , < * [ E" !

ZY[

5) , S ( O

%

V( = ()

# (

j E" !

ZY[ V( '()

* "

3 () > 5, =

"

R overload

G7 overload# <

0

!

C

"bJ _ /! <

3 4

WWW.IRANMEET.COM

(E.D.T)

!

Elementary Data Type

- . $

/ 012

" # $% &

56 7 %( *& 1

21 3

"4

+

*( ? => <; %

,-

!

, $ . ./ 0- * & ( ) '

5 1 ", : 9$

8( 3 . ./

Data Object

8( ( @ 1 E + $ %( *( ? @1

BA

*( ?

$8

'

C

%(

!,D + & ,/

G ' # %( 8( ( ( H *

>

8( (

,0 I

" # 7 !"

$ A 8( (

( ? JK?

8( ( @ 1

(H


BL

!' M

#$ % 5 $

%# I

N (H I

( $

O &,

4

%(

!"

?3 &,

$ !' *

8( ( "

#

'

&

#

&) ,

! P

# ! Q

%( R !0

) $ 8( (

5S *( ? JK?

BL

!' M

F

*+

8( ( @1 *& 1

* *&1 Data Value *&1

9$ 8( ( V 1


T U 5>

0!4 5 1 A

5 1 ", A

> 9$ 8( ( @1 8( ( @1

Structuerd

*&1 8 W $ Pointer I Character I Single Number & *& ,

A: A:

T U %(

+(

5 1

*( ? JK?

X .9 M

A:

0000000000010001

10001

A)

# 3)

.9

3

>

C

Y( ?

8( B *&,

%( 17 (& 8( B

#

+$ Z4

[email protected]

% &H

8( ( @1 #

5* 34

( ? & H 17 8( (

%(

WWW.IRANMEET.COM

, [@1 \ ( H

]

!' [,0 *( A [ ) '

%( ( H 7 . $ 6 !

!4

*( 1 [ 8( ( & ]

Q $% M

",3 _

&(

-D #

89 :

\( H 7

$ 7

6

( ^C &

7; !

[

) ., $

%

(M

7 `<

( H

^3 ) ' declaration

M

( H 7

7

6

A 8% 1

[X

*( ? 8( B

c L

O % L

8( B

?

) .,

7 6

$

$ #=>

6 !

7

6

$

7 6

$

M

*( ? & H <% &H :; % e *&1 [ " # <% &H :; % & # ( 4$

T>9

! "# )

% T, I(% ( % (

Life Time

?A $

6 !

\

] 8( ( [@1 e

O e

\

] 8( ( [@1 e

Ne

#)

\

C \ T U

6 !

7 #=>

$ 8&1 d 0 _

$

#=>

*( ? b L # *( ? 8( B

$

[ ] 8( (

*( A [ ) ' ] ' *( ? a D

*D . $

] 8( ( [@1 I<[ U:]

f 6K Life Time

U *

1%

Ne

/ 8( ( [@1 7 %7

& ,\ JK? % [ U

N$

N I O *Q S

Const Max=100; Var N: Integer; N:=27; N:=N+Max;

*a 4 <( . &

[ % &H e MH : %\M

&1) ! \ 4 I

[h

*& % A& *&1 [ ]% h ( $ & 9 ]

] 4

O

8( ( Z X A ^9 !

]

! Q

4 e

*& 8&1 JK?

N e Max kl

*&, D [ U

N 27 $ 100 km

[,0 g@ > #$

8( ( i 1

d 0 ) ., 3

[

#$

A *& $

\ 8( (


BC

8=

Z

O

7

` Data Type

\ (% ( 9$ 8( (

7 ! #$

O N kj

8&1 d 0

? 8( ( e ! Q

!' 8 !

8(

]

!'

7

*D EF

e

6K? 7 0 : ( \ d 0 kj
[email protected]

. $ . $6 8( 3 kl

WWW.IRANMEET.COM

% ( 0 5 1

*9

8$

% (% %( S *&,\ [ &4

. $ 6 / PD% U

H

%

7

f

[ ] 8( (

] 8( (

%# L ,



%$% L

I]% q

K

M @B 7

] T U2 ! $

! `p

%# _ & I %#

`
] 7h! ] " % h (

#i 1 o

$

e \ [B K ] ; % `
I

8( (

. $ 6 / CG

\ [An $ `
( . &

EF

[h

7h! \

*&1

5 (

%

G =0

8

G [. ./

! ]

8( 3 8 >

(

]

!'

$E / H0

&

./ 8( ( i 1

# \ & ,\ [ 7 0

*&,1 8&1 d 0 _ 5h 1

_

8&1 d 0 8( (

M

\ &,1 [ !

M

8&1 d 0

8( ( [@ 1 e p s %&+ \ ]

e ]

%$9$

!

\[ !

7h!

! I& ? d 0

!'

! 7 & 1 ]% h ( [?K

5S I<& ( A [ d 0 &

]

% L

,

9$

!

r \ %(: & ?

1

*&,\ [ - > % c >L ]($%$ !

, =

% 3 ]

%$% <& ! :

% 3 &,/ e \ ]%

8&1 d 0 # ]$% & ,\ [ JK?

*&,\ [ JK? %

!

!

I

]

& %( ( 4 Z % .9 I(% ( )

! 5S #=* $ #

K

% L

I

]

=

% L

R !0

!' *&,\ [ & 9

% ['

!

& a s u

$ !IAJ!

*&,\ [ 8& v 3 % [t % E ZD H

[t % E e

\ ]($%$ ( H

! ( h ! Z % .9 [,0 I& # Z" [

I BL

I( ?

O 5 S & 8&? d 0 c L

% L

*&1 - 7h! 8( ( i 1 ]

%$$

]

! / H0 #

]

#LM

!' $ N

! d 0 [

7R ! 7PD% I

I !

5

, ( p +( 7 0 Z

[email protected]

O 0 % "/

! Q 7 H0 kj

, ( p +( 7 0 [,0

\ [X " ($%$ $ [,!t ] " ($%$ ` 7=HS I A J !

^3

( 1 ) ' [ - > / ]($%$ ]

&1 [ 5h? ]

! 7h! u

!

\& ? =

]

T kl

WWW.IRANMEET.COM

7 h! E

S I& ( ) ' q % ] . ( Q ! ( *

0(]

[- 4 N [

%\7 & (

O q %(

&,\ & 9 [ ( 6 ( & *

[ L B F$

8$

]($%$ ]

A%# I[ ?A % &H !

e \ [ % L %( S `

5-+

DU

! e ` 7V$

7h!

[9 S C %( e

O

!@

/ N km

8$

: 7:1G

S *( ^3 [

4 [ -+

+ kw

4 &0 A. $

Q S

,

] .(

\ Z %( + *$ *

$

7

\ Z X . Z % ( 5 ! x W Z ,\ [ d L

Dh " # % % $ &, D c >L

% # I&1 5h 1 7

?

A%q

[?K

,

*( \ ( ' % 8

T U

[

A *( 1 d 0

[ Q h 3 %( Q S *

[ 8( B

[ A A ] 5h1 I char $

ly j

, " 8( B

,

; (H \

$ 4 ]R

Dh %

% ]& &4 8( (

short Ilong

I int

C %(

Ia t IE!4 &, [ !

*&, A super Type

A%q

type SmallIntege 1…20 SmallInteger 8

c >L & %

[ +$

Q h 3 $ C 5S [X

%( *&,,\

. $ I e!\ % q %q K

K K

R !0 8( B

9$ 8( ( )&

[

$8

% L %( *& ?

\ [ % L %( [!+% 24 ( & ]

G ] ` 89 : 7! [ - ?3 % q

K

-1 S :*( ? 8( B

&, # [ %( 4

;$% &,/

!

/ 012

+W 7?$ ?> &

Integer ( & Q S

,

_

%( &\

% L

SQRT

$( ? ]

%

A

-1 ] e ,h

<&,\ [ [ - ?3 % [!+% 12 ( &

S\ &U % q

! (% 7 %( ` / H0 I

M 7?$ ?> &)

( 5S ]% q ) ] 8( 3 % q

*( ?


c >L (& $( E!4 5S % q ( & %^4 7 A ]

M 7?$ ?>

K p

K p

! H D kj

-1 p

' $ 3 E e

,

kl

!HD \

%

,

km

(

] 9 -(

Q S *( ? 8 ( % + ABS(x) = if x<0 then –x else x a) Fetch value of x from memory b) If x>0 skip next instruction c)Set x=-x d) Store x in memory

[email protected]

WWW.IRANMEET.COM

W/Decleratoon. "# "# $ !

#%

&#

333

* #+

! #*

# 0

"2! /type.

* 1

&! '(

") &

* +

3"6 & 4 '# C

#

7"#6 "# <

> #?

3

#* ,

B A

:& 6

2!

> (

; ! <= A 6

7

&86 ,

float 4

7

,-

' &5

( 3")

4 9

&86

"* &

@ float A,B; 3"

# Fortran J#? 3"#* & C A 6

H IB

&C * D + E F ! G :& K

B

L H4

i,j…n &C * 1

&

! "# !$ 7 7 7 7

> #?

#)

# P" #

* +

5

Function Sub(int x ,float y)W Real 3

!

: & TU@

A 6 ,

M

A 6 4

M

$

M

A 6

"<

O 6

NH M

&! '( ") ! & * '

4

7 '

F 4 PV ! ! P "2! Q ! R ' , S)* 4 05

W/Decleratoon. 5 #G

B

1

NH 4

Q

&! '( '

: ",-$.

3 6& YU #

#[

P"#)) & TU@ ]

&# ^# 2! &#

"

Z a #5 Z P New #S5

C++ 3/ #5

@# 4 # 3 :& ,

> ( * '

&C * 1 , ! > ?

)

F " :&

J#? K+ [ T IU!

N

,

* 1

!B %

> (

cdc J? &H B #:

L #H Q *

: Z4

." S *

S

* ! Q

")6

!

% P"*

% K+ [

/"

& _` &C F

P" 6

" P > (." 6

* 1

5

V !

[email protected]

>? 3 :&

: 3 6

malloc() Q !

C

_ polymorphism3 + 0 * BP A : A+B

$1

3")) & 7 N H

=

)( )* M\

",-$. / 0

H 6

K+ [ a 5

$+ ( MX

% ' $ ( )( )*

K+ [ E

= K+ [ a 5 R

=

")6 L H 4

$

Z

3 :&

* ] ; !

%

@ Q

$2 Mb

^5 U ")6

WWW.IRANMEET.COM

/polymorphism.&# U "#)e &#N5 U

#*

, %N

# 7 F" !& *

:& ,

fB

5

3 6&

ML

: Z 4 V_[ &! 5

N: Q !

Q !

V! !

J G

P

_ 4 > ) ,

7

!" :& V 3") Y U V )

4 > )

* ' h"*

& U ")e J

overload

(

%

"

Z

;_ J

(

% ' 3"6

6

:Z

!

*

W Type cheking36 ( 7 # Mg 3

F

W/Type cheking.6 ( 7 # # 7"#6 #% Z 4 # #*

&' 4 i

# '(

P # : &# , #

* 1 J? 7

# " ! & 10001001 &

#

&! 5

A 6

6 '? P "

*

Z

K)

5

H&

]+

U Lj

3 6& ,

Z &

J G

3 :&

4 > ) 3"6

*

: Z4

"2!

8 6 (7 #6 (

Dynamic Type Chekig3$ ; 6 ( 7 # :9

> )

HA

h"*

4 > ) 3"6 &

]+ , Lj

3"6 3 6& ,

4 > )

Statick Type cheking3$ = 6 ( 7 # :<

> )

$; 6 (7 #

> ?$@(

- 2 3/ K+ [ #

#% # 4

Re

e S

)% 7 N .4 3" 6 & Re 4 3 6&

M

'( % Z

"%S &C

&C

,"

M

* _ , ! M

> `6 P : & , $; 6 (7 #

A ?$@(

kF h j2 M P

7

A #6 , # !

' ^ 2! /7

> ) fB

." *

B

E F &!'`@

`

*

J< _

]

5 G

! P& U ")e

5

% M > )

$ =6 (7 # kF h j2 "6 6,

[email protected]

" !& 4

*

> ?$@( M

' ^ 2! M

" !& *4 J"!J

M

WWW.IRANMEET.COM

3/

*4

1!

3 3 &86 *

*J

> "

#H 4 # > ) J

P 5 G

,

k:

>

7 F

k:

5

3 6 & TU@ *

&C

M

J`@

7 N

> `6

% &+ m

n+ M

J$

J G

: Z4

A ?$@(

&86 4 7 Bl

]+ , ,] `

3 6& ,

.

$ =6 (7 #

M

> ) P _ 4 > ) V ! ! P "2!

5

W `

*

4 P7 3 kF &

J[

/Type Mismach.") _ &` 6

F4

jB > )

N: 4

"

TypeLess

*

")) & 7 N

5 3

Conversion : type1  → Type2

3 6&

7"6 ^ 2! 7

F4 > )

[email protected]

: &C *

4

&

W `

S jB

M^$

H4 J"!J

MY

&5

W `

(

WWW.IRANMEET.COM

5 0 '

* 2 3 4# Type ) * 2 3 4# Type1 Type mismatch + . Error

Handle

Error

'

conversation _ op : type1 → type 2

/# 0

&Type conversation%

!"#$

! "# !$% & ("

! 1$ /- *

";

- 0 &Built in Function%("

) *+,- . $- /

!"#$

; 0 /0 <; 0 ";= %9 :;* , 0 Round 0 )* "2 3"2 ( 4)* 5 - 6! 7

0 7

8!

&") > );

B );D

9 ;F

;2

-

"; / ; . ;$ C! ' EF ! "G >

#L Int ( <

3"2

0 Int

)4' O >2 M

@A )

!"#$

!H

3@ 2 >

- ># $ 3K F

Float

!"#$ 3 !"#$

J!

B* $ C $ $

>

#* ?

!"#$ 0 . $ J!

/G

!"#$ Float

$

!"#$ 6 ?7

0 7

I 6 ?7 "



• @

'05 ' 9 :* , 0

>2 M 0 N

!

. A , '() *+ +

/ ) 0 3/0 < 36 ?7 "2 /0 ";= C;$ ;!

:;* (

S

0 "= "2Q / 0 "2 $ >

3T* U 5 0 "=

";* 2 >; 0 ;U 5 0 O;I TD;*%";2 >; / B* $

G ! 05 "2 P&R

5 " 0 "V T 7 W C! B=I , 0 OI TD* /0 1 -

"2)XG (" Y , / G 0 ) * Z 1 /0 "= "2Q ! R "

"2 P& :* %/0 "= C;$

/G(

> > # )<,

:* ( &"

S >

%/0 "= "2Q

/ (

, (

S

> 0 N

*+ + > )4'

A 0 OI TD* B* $

=)X 0 OI TD* B* $ "

> " $ !H P (

& 3/0 < 36 ?7%/ " J ) 0 , ! 05 G !I G ' (0

[email protected]

=)X

WWW.IRANMEET.COM

TX

(

-

>

! 1$

T* /0 "= "2Q O 0 0 P 0

B* $ 0 0 + 67

;

;

#; >;) I - 00 J! /

";2 >; \D<; 0 2; O;

*+ ' * 8 ) ) 2 9'$ + %

< ( 4)* IEEE 754 0 " )* - 0 2 O

"; /

0 >)

>)

64

32

" /- * ( , (

0 " )* IEEE 754 0 " )* @ 2 > ( 4)* > T* !-

E

S 1

127 0 "= >) 32 ^I V 0

$ /- * (

[

" 2/ 2# 0 3"22 > ( "

> 9

[ (" 9

2G 0 >21! 3127 > OI

0 7

0/11011> TX 9

0/00111 9 F /

0 T XL `0 -

J! 5 J)

!,0

=

aQ T * - ("

;M ;7 V 6 ?7 T XL J)

2 " 0 > )

L J)

'

0 " )*

! 2+ %

>) T
$ , E :'

[ 8H* (" ( OI

" Z 1 T* >) 238 ) , M :'

00 2 O

:

32

47 >) C! T E " I , S :' > (

(" 9

>)

0

23

;T* T#F / 21 5

0 7

M 8

[/

3"

0 < T XL T J! $ _-0

2

+

10

2

> )

"!

<% + % ! "# * 8

X=$ B* $ 0 6 ?7 T XL

M - /0 < T XL /

@ 2 > #* ? T* 0 T *

> ( 4)* 0 < T XL / _-0

T *

(4.75)10 = (100.11) 2

;> ?

0.75 * 2 = 1 .5 0 .5 * 2 = 1 .0

) " 6 ?7 T XL "! >21! @ 2 9

0 " "! ") IEEE 754 T I >b

> @ > ! - .L (100 .11) = 0.10011 × 2 3

#) #

T* >42 / G

127 "

(100.11)

" (

[/



TL @

3 + 127 = 130

"

S

E

M

0

10000010

1001100…0

1

8

23

>

: J!

^I V 0

[( ?

XV J!

8,

!"

$% &' ( "

- >G"G

$ N

" J! (

0 7

5 +!

0 2 O

T I R L 0 ^I V - (" ( T

@G

[ " ` D)* >21! 8:

8, 3@ 2 > ( 4)*

1 1 1 ( −1) 0 × ( + 0 + 0 + + ) × 2 3 = 4 + 0.5 + 0.25 = 4.75 2 16 32

[email protected]

(−1) S × (0.M )10 × 2 E −127

0 9

I

WWW.IRANMEET.COM

"; ( "? $ c0O > T; ";1$ E - 0 ^2

" ( "? "!5 > T*"

- >
Z / &Exes%> OI 0 "= - Z 1 P 0

$

d 0 - > OI 0 "= J! Z 1 @ 2 > ( 4)* CQ

(2 E −1 − 1)

" T; C;! 8 ) ; B* $ (" ( >;

";

;

+!

TL

>; C;! +) J! $ _-0

; L

(0.M + 1)

;

O

$(

; 0 J!

>

I M (0

"

< G

> !-

-0

T* J! 0 J! efV /- * (

5/G

L >G ' P 0

efV 0 8 ) 0 "= J! $ _-0

/ 2# 0 (" 9

>

" ! +! OI

[JV0 0 5

$ T*

- *+ + @!- , > G ! 05 /- * ( , (

[ >*0

R

/G(

)D 0

, @ A + /"; , TX; - "; 0

4) 7 2

! 05 / %"2)XG

;^I V 0 &0 ; %/";1 C;$ / ;G ! 05 - >;:! T;

"G

i g

(

hX /"1 "2Q

#;* ? "2 - 0 J! /

C! - > G

[ &@ G > " , @G &8! $ %/"1

T* ^I V >:!O I j0 5

* '.B

"2)XG 7 2 - /

0 72

/ G ! 05 5 72

7

' (0

#

G ! 05

@ 2 > ( 4)*

3 '>

/ 0

-

>' *

! 05 T

$ H

G !H @G

!] / (k! *+ '

;! 05 ;7 2 - C;! ;G ( "G

!- :

[ TUA -Z / G T! 0 "= W2 (

I

[ ? 3"

" / l;I $ H ; ;^I V 0 ; &column

maior%>

"

E

^I V 0 ! 05

! 05 8!" /Z "V UB

> /"1 C$ >! G ! 05 / 9 Q 3@ 2

)* _ 0 n &Row

!"#$ 0

maior%/

"2 > ( 4)* > )* _ 0 -

J

! 05 8!" J ! , "V LB "

I J!

loc A[i ] = α + E × ( I − LB )

0 5 ") "! 8! $ C! 7 2 j0 5 " $ /

d* _ 0 m _ 0

$ I / d* _ 0 -

Z 1 j0 5 9"#$ J! 3 0 " 21 /"1

A 3 9 :* , 3C "2

G

4 )+ 0 ; @ ;2 > #* ? 0 >;

A[ I 1 , I 2 ]

A[ I1 , I 2 ] = α + disp × E 9

W;2 $ ! 05 9

W2 J

72

j0 5 α '

I @!0 0

- - /0 X " 7

A [ LB1 ......UB1 ][ LB2 .........UB2 )

"1$ disp T* ! 05 W2

G (- "

@ 2 > #* ? > )* / d* / G _ 0

E

' "A

C D) ! 05 @ 2 o I

/- * ( 0 7

>

[ "# α 5 0 disp " P/ d* _ 0

disp

#0

12) ! /$ /

= ( I 1 − LB

1

) × d

2

+ ( I 2 − LB

,- # .

2

)

5 #

3- # .

*+

[email protected]

,- 4 # # 0

2) # .

WWW.IRANMEET.COM

> )* _ 0 = (I

disp

6 #

12) ! /$ /

2

− LB

2

) × d 1 + ( I 1 − LB

)

3- # .

5 #

@ 2 #* ?

1

3- 4 # # 0

2) # .

,- # .

A[ I 1 , I 2 , I 3 ] = α + disp × E 9

I

0 /"1 * ! 05 @ $ > >bZ _ 0 J G 9 V / d* _ 0 disp = ( I 1 − LB1 )d 2 ∗ d 3 + ( I 2 − LB2 )d 3 + ( I 3 − LB3 )

> )* _ 0 disp = ( I 3 − LB3 )d 2 ∗ d1 + ( I 2 − LB 2 )d 1 + ( I 1 − LB1 )

@ 2 #* ?

A[ I 1 , I 2 ,

, I n ] = α + disp × E 9

I

0 /"1 n ! 05 @ $ > >bZ _ 0 J G 9 V / d* _ 0

disp = ( I 1 − LB 1 ) d 2 d 3

d n + ( I 2 − LB 2 ) d 3 d 4

+ ( I n − LB n )

dn +

> )* _ 0 disp = ( I n − LBn )d n −1d n − 2

"!0 HX N &T* 0 &aQ j0 5 ' T* (" (

[ / d* _ 0

"!0 5 T*" 0

0 !-

aQ - %/ d* j0 5 T* 0 - %> )* j0 5 T* o 4

A[1,2,2,2] j0

5"

d1 + ( I n −1 − LBn −1 )d n − 2 d n −3

d1 +

+ ( I1 − LB1 )

E A T* )U p I / G 9

I

q4V /

Σ &8!"

"1 5 J ! , "V % × T* 0 T * 1

Σ &8!"

A[1 10][1

! 05 W2

"1 5 J ! , "V % × aQ T * 1

20][1 10][1 10] /"1

G / G T!

"1$ "

0 UQ ! 05 P9 F 47 ^I V

disp = (1 − 1)20 * 10 * 10 + ( 2 − 1)10 * 10 + ( 2 − 1)10 + (2 − 1) = 111 a[1,2,2,2] = 0 + disp * 2 = 111 * 2 = 222

*

[email protected]

WWW.IRANMEET.COM

8 4 5 6' + 7 %!

.2

!33

' " 0 / +1 ! "#

0

*

$1 2$

3 / &'

()" *

$ %

'+

-1

,

-

. " $ / &'

( & " / &3 $ 4 5# . 1'

6 7 8".

! ?@$ &3 $ 4 5#

+ 9 :;

$

/

$=

6

9

< >$

6

7 2$

@'+

/ +

-

6

-

# 8".

6

2$

A

$

9

-2 &.

< /

()"

7 8".

$

-3

$

2

* B C

$

6 ! -4

! ?@$

FA.D.TEAbstract Datea TypeD" # <

$

+

7 8".

(

+9 <

$

$ -

7 8".

B $

4 5#

/ + I J ADT (' +

!

8". M ' 3 &5$ (

2$ (

+ $

$

'$

&3

9 :;

) )ME

" $

-

K 'L

;

3

!

3

'$

9 G$

'

+ $ 9 /

1'

-7

"

+ $

!

Q V

) )M

Q7 TU3 !

-WK

1J ! '

6

-

9 (%

&'$ #

5 N O+


R S 3

+I J D) *

TU3 9 U.

C++


ADT 9

3 # 2$ H+ #

- $

+ $

B ( 5# G". -

'$ $ +

- & !

$

?6 # 2$

/ S

. " $

$

3 ME

$

-

/F 3 ! . '+ $

@' + UX$

$

7 ,16

+ K'5$ 1

B 2 / +

?&

3

&3

@'+ )

Y J

$/ +

$

7 .US Z "

[email protected]

$ + >

$

7 .US ('J B [6 I'

/ %

+,-

9 3 # + ?&

'

) 7 ,16 Sqrt(): #

WWW.IRANMEET.COM

. 2$

+ $

G3

Z " 7 ,16 9 <

$

3( :;

& '+ U$ 3 %

$ '@B <

&3 $ $

[P

$

&

@'+

-

%J R Z " 3

?-

$^

# ?-

_85'$

*

# $ \'$ 9 3 7 8". K

+ 6 $ -

/ %3,

]$

. " $

-

\'$ U.

7 8". ( !

3

) )M

?# Z

%J R

7 8". / +

2

9 +

:&

#

.

)M - 7 ,16 /

6

Q & # $ 3 &5$ (

&'

4 "' ;

?& 7 .US I ?& 7 . US

FSubprograms a Abstract operationE% 1J $ 4 8'c$

/ %3,

Abstract

! Q a`

I ]' $

'+

&' . 2

6 ab

,

+

1

Subprogram

/ &&3 6 I . <= FNameE! F4 ?-

d# # ?-

Subprogram

$

g

7

'$

5# F=

d# # f ' H+ #

!

5# Fe

7 8". F

Subprogram

Function FN(X:Real , Y:Integer):Real FN: Real*Integer → Real

Q "5$ /W X$

. > + +

\'$ GX$ '+

@ /

7

I ]# GX$

FHistory SensivityEGK; $

\# GX$

I?K$ ?

'

&"g

?

+ (2"$ Subprogram 9 @?

'

&"g f '

+ (2"$ Subprogram 9 ab

]$

i5

+ (2"$ Subprogram 9 ah

T R FSelf ModificationE \#

[email protected]

+ (2"$ Subprogram 9 aj

WWW.IRANMEET.COM

4 ) 6D !

Subprogram Definition and Subprogram Activation

4 5# #

&3

J

$I

JF

%>

$

5J ] +

E Activation

?6

$ D.O

Life Time

4 5 6'

! Q 7 VcL$ 7 . US $

L$ -

J Type 9 4 5# /

8

%

.

/ %

E

+

. <=

_

!

+ ! "#

3

&")+ 3 '

# $ $

" ;

6

P3 9 / "

A

J

$ !

/F &3 $ (

g $(

" ; 6 (R

5J

3

G2 E J

3

'

B

8>$ a

f '

k

8>$ a

\'$

k

8>$ a

]$

k

8>$ a

# 3

k

8>$ a

9

+ W 5J

$

Zc

6

A

^ 'L$ $ J [

]$ 5J

J 3

Zc last Activation For FN

second Activation For FN

Activation record For FN

Activation record For FN

%>

k

Zc (

R(

Code segment For FN Frist Activation For FN

?6 '

"#

'$

A

Literal

L$ $

2C 6D A

8>$

, 6 3

$ ('J

% $

6

4 5#

Activation record For FN

Zc

FGeneric SubprogramE D3 3,1 % + 7 @'$ ? - d # #

'$

5# 3

6

2

$+

$

# ( &M 3

+ (

%&$ W X$

procedure ENTER ( student : integer ; SECT : var Section )

procedure ENTER ( st : sec tion ; TAB : var Classlist )

begin end ;

begin end ;

[email protected]

WWW.IRANMEET.COM

TU 3 5#

Section

6 #

8 P$ 3

J

9 !

$

+

!Q 3

$ Section 9

?6 &3

3 & B J J

L 9 !

&M

$

83

KA

W

$

$

9 ! 3

$ Y J W X$ B ( / &3 $ J g

$ l cL# ? d # # / &3

'$

#

S

$ $ 5 6'

DFType DifinitionE /

+I

J

6 $

6 #

Type

6 Type 4 5# /

?6 # 2$

+ $

$ Description 9 G$

9

Name 9 G$

Type

/W X$

type s : Array[1 10] of Real Type

$ 6 $

' +

- $

6

7 .US

8 +

C

+ ?& ]$

8 +

3 #

2#

Type

'$

+ a` B 86 ab

W ]'

3 #

& '

'>$ -

5 6' % #

+ ah

6 G2 9 aj "F B

%&$

C T - -

3A

"F B G1 3A

%&$

% 7 8". 3 O

& K

+

5;

2 B

$ B-

(

]$

$ $ 7 8".

$ 'J [

/ I(3,

$ $

) 6 E 3> 2 ?- ! $

!

3

Type

7

2

B $7 !$

9 # "

3 &' B 7

SUB(Y)

2 (

) - &3

# /I

R(

$=

# " !

Type

[email protected]

H, W 5$

Type

:

#

) 6 a`

3 5O; B W X$ W 5$

B +

I

I (

'

Name

8

+ 1$/ )

) 6 56K J A 9

a

Type

$ G2L$ M

END .

>$

>

'

@'+ !

+

- %'

21 Type

W '&3

B /

: W ]'

M

&"g G K#

End Begin X := Y ; SUB (Y );

'

$ B- &

. ; 1

/ + -

Begin

M

$ I ]#

Type VECT 1: Array [1 10] of Real ; VECT 2 : Array [1 10] of Real ; Var X , Y : VECT 1; Y :VECT 2; procedure SUB ( A:VECT 1);

7

'$

WWW.IRANMEET.COM

W ]'

# "

SUB()

6(

w

/W X$

Var W : Array [1 10] of Real ;

@'+ G ; $

B 1 Zc

$

+ +

4 5# 9

) 6 ab

FStructural EquivalenceE /

2

@ $ ! "# 7 ,16

I F

$EW 5$ ? - ' + B &'

/ +

+ $

Q

a

I W 5$ Type

[ m O5

I

R( (

1$

".

) 6 56K J A $

8 P$ 3 I

$

+

$

&5

&1 n

B 6

?- <

$

B

'R &

2

' + %

W 5$ l cL#

Type

& 5$ Type J V#

?6 a

- 3 &3 m

S

+ (2"$ \'$ /

a

3 4 5#

Type METERS = Integer ; LITERS = Integer ;

/W X$

Var Len : METERS ; VOL : LITERS ; X := LEN + VOL;

' + <

$

M ( &M 3

"

'J B 8 P$ 3 m S

,O o

$

'R / &3 2"3

+ $

$<

Z

+ (2"$ K' (

/

+ p>

[email protected]

LEN+VOL

$

+ $ 2 R

+

&&3 $ 3 $

9

2

WWW.IRANMEET.COM

! " #$% % & '

# $% &' '% ( )* 2 > B 7 C B 9,

34 5

-

/'

@%

?

'

6-

,

B

B

B

B

G

4 $ 4

= > 7

H - $ $I

,7

/' /

0

"!

9 /' /

0

"1

/' /

0

":

J, G

DK L <

4 8 ,-

A ;4 < )*

D E 0 F, 7

7

+ , - .%

0 K )*

,7 9 /' /

0

"M

#, H 4 D

B ,

> 7F

P KQ<- R

-

>

- B

6 $+ 7

H

#, N # J, 7

O T+ * # $% &' )* S

? <>

4

L '

V,

F

-

4 5

6U, R 7 -

O

7 /

7 /

+ , - .%

( )* ' B > LB

B - B

%$D /' / B root =

> L 'X Y R )2

B D 9, [Y

B /

&4

),'. W (

/ 84

/

; X

3 4 6D 7

J, B

L,

. Y

,7 '

)( '3 6- .%

C B

&' 4 ,`

L 7 -

9, S D

, 9, cK

,7

7 9,

K D0

7 D

6 ,Z

\D

' BR 0

4

A 6 R - $% D0

− B ± B 2 − 4 AC 2A

^_LB @* T CB

A 4 L, 9

#,'2,

" #$% % & '

0 F

* / ? < 9,

,7 / Y 9,

7 'X , 4 ).( &

.%

,`

D

0 , T'X

[email protected]

6'

' '; &#

,

8&a

4

L, N4 9,

#

D, ; ] ' $

^_L 9 b$

R N4 4

S

WWW.IRANMEET.COM

!+ , $ !+ ,-. !+ ,/$. 01 $X

5

#

%$X,

* SQRT

2

D 8

/

B+ , - .% QB, $

A

)* '

B

!+ , $ 01

4 >$ 8

( ' $% 4 9 !+ ,/$. 01

+ , - .% Q, $

)2 9,

@* '

d ' $% 4 VZ 4 #

%$*

**

!+ ,-. 01

VZ 4 ' $% 4 N4 9, B

2

C

*

)* '

d - .%

#

%$A

4

4 6'

)

'

$

7

> 7 J, ;4 '

O

- .%

' & X

- .% . Y

* > %

' -4

',

4

a '

&

#,

D 92$

J,

9 X >`

# $% , 4 '

%$&a '

6- .% 7 Q_ 9,

DX +4 9, ^ _L

&a D

(b / 13 − 1) 7

X, D

)

&7i ? &4 * # $% 6D $ /

/

'

D

k 5

',`

' _ a

' m

= H0

Q< R g l

9,

$

)$% J,

- R

,7

D$ - .%

7 6'

7

D$ - .% @R 4

6D

'

7 > ?$ R 4

8 /

I &

k 5

6

7 V< D

' 0 m H0 ' _ a

'

, ` '3 7 n 0 I4 ' g &4 - .%

,7 6'

[email protected]

,7

,7 - .%

*

R

'

8

h;

'

/

93

#,

* > %

- .% 4 9, 8 9,

/

While( I < UB) And (V [ I ] > 0) DO '

9, >

'

7

j ); 9$ '

W

%,' +

- .% 9, ' 6'

,7 7

2

)$% 7 J, & ' D

', # O

Q_ 9,

.

fX . Y

%,' & 5%

if ( A = 0) OR ( B / A > C ) Then ...

9, >

7

,7 >4' - .% a 6- .% / (13 * a ) * (b / 13 − 1)

g 6- .% '

2, 4

+ , - .% 7

4 $

8 e;

4 7

32 ( )* > %

23 1

7 > ?$ ;4 - .%

)2L I & 2,

7 V< * > %

- .% 4 9, 8 R

)2L

WWW.IRANMEET.COM

6' m '

,7 )2

'

= H0

9,

T >

$

R 50

7

R

D$ - .% @R 4 H0S 4

/

* )2L cK

/

> 7

;` J,

if ( A = 0) OR else ( B / A > C ) Then ...

H0

$

,7

D$ - .%T 4 - .% >

D

S >

R- R

O3@

', Q < R , 7 /

K , D0

,

&

a,

DK 8

(/

L /

" #$% % L

;4

> 7

'

R 4'

4'Y >`

-,

7,8

>` 7 > 2 '3 6

D$ (

X, '

'

n4 0 H J, 7 /

&'%

4 4 4 H J,

0 9,

>'

7 D$ ( 7

'

2, ' & a

D 9,

O

^_L )$% J, ! 9

i

=

9

4 ?K D_ 7

J

/

.$ > , ' V,4

/ D3 4 /

R I_ >` V,

k' 9,'

'

" "

>

7 /

` "

7 o@ J, " # 4

. D D

K , D0

,

k@0

p.H

- R

0 >

e X+ , 4 ^

`

4?;

9

-

D 92$ -

7

9, 4 ' V,4

k' 9,'

' &a

E 0 )$% J,

1; 8 ;

'

,:

for i := 1 to k do if Vect[i] = 0 then goto a ( a is outside the loop )

7 D$ ( <.

"

>$:

',

" "

% $a

"

K , D0

2 :

: ?1

a,

,

@ A + B 3C@ D

=

End . Loop Read ( x ) if x = 0 then goto a ( outside the loop )

4

process ( x )

,h< W

3 J, ( ,

- XK $

End Loop

D

2

7 /

D; 3 9,

8

[email protected]

,

-F

E% "

' ) -i 3 $ n 0

37

0` XK 7

j

WWW.IRANMEET.COM

4

6

6 R

# < ' XH( 9,

'

d4 6' , 8 q *

',`

Q<

93

7 ' / >`

)

q *

G H

F,

$ (

7 /

D

&r
DB s H B

,7 7 DL8 4 #,

B,7

>

B

C 9, /

/'% ( F

&a !

;

DB /'B BK 8 O

,7 , 4

0

9, '

B0 K

,7 7

> 7s 5

,7 J,

#$% % & '

0 K

,7

7 /J =

S

!

Z J,

7 P Kl
7

4

T"

7 ).(

,

/

> 7 *

6

D 9, )*

D; 3 9,

0

,7 (

8

&

0

0 K

g 6

- R

0 K 7 '

T' ' B

4 Y, R

0 Kl q *

,7 D 92$ T"

S

0 K

N 0S'

N7 <

4 $

L87 '

D

'

$

,7 U, R

)

5

',

0 K H

/'L

0 K7

,

' e(

,7

7 V< 4

H

8 6

/

,7 "!

0 K

7

0 K

N AE

+:

F,

AE

M

+ $J

B

B 4T B

B

,7 9 S B B$

,7 e, X 9

; ( J, ',`

4 '

,

D K, *

" &@

/ B >`

FB

@BXK B ,

C46 ,

9,

D

a, e, X 7 =

'

: &

8/ >` /

'

P

A+B

D

#,

,7

93

4

0 K

!

[email protected]

/

Q,

9, D >`

#$

>`

D ; XK >$M

C46 ,

H

XK ,7 '

0

h8 -4

#$% % & ' 6

,'

' LM

>` e, X 6

6

4 ' D $# J

?

"t

A + B E ,O

" &@

.; ( 7 /v

,

`

+@ 1 K;

/'% ( P K u <

, /J

B, , BZ

0

"M

,7 J, F K > 7

+: DB ; XK

5

]Y

D

4 +:

)

,7

F

E J

"1 ,7 ":

D /' ) N + ,N: N" K 9 M ,O

H

.%

L #

I :"

J 3

6

'

:

WWW.IRANMEET.COM

B0 B

B

B

9

'B BXH( B w

6'

/

/ B

x 6

DB ; XK

', $ ^_L

B

BR B

/

B

%$4 #$

K 8

7

,7

T'

>L

r >` 6'

R

' D $# 7

-4

#,

a, ',

0 K 7 'X H 7 ,7 C4

9 ;4

,7 >` 7 D ; XK

0 K> 7 R

,7

Subprogram B 15:

###

! 14:

###

Call B

Call A 13:

"

!

###

"

constants

R1:

R2:

R31:

--

11

14

--

R1

R2

Local

Local

Local

Valriables

Valriables

Valriables

etc.

etc.

etc.

CIP:

15

CEP:

R3

"

[email protected]

TD

', 6D

K

X

r

X

#$4 '

XK 6' X

/

J, '

R ,7

,7 ' D $#

6DL87 > 7

Call A

###

/

' 0/

Subprogram A

###

6'

:

Q , Y D 92$

D; 3SD /' L8 , I

###

12:

%$ 8 /

'

XK ,

Main program

11:

'

> 7

B / B >` B %$4

DB ; XK

&$ >

4 D ; XK

C4 (4 6'

9 B;4 B #$4 'B

D ; XK

6

R

0 K B

O

C46 I$R J

8/

,7 J, D ; XK

,7 >` D ; XK

B

D

' D $# J, 7

(4 * > % &

S XK D ; XK

'

/ 0v

D X( 4 9, ,7 )2

WWW.IRANMEET.COM

34 !" &'"( 4*%) #

*" + , -.

( # ,89 * " + , -. :" ( * /) >=

? 1" 1,,70

#

,

/

#

+ , -.

$ %

E*) * 7 J -.

,

/K

"*, /56

,@(

1,2

#

+ <.

C ,B "

*%

"

&'"( ,

!" "

# #

$ %

*7 + , -. ; /0

" 4 /) #

A*

!

H

!" /%.

* /)

1?-

$ %

3( 4*

1,,70

$=

C ,D !"

J-. !" I,

+ <. < C

0 , -.

#

5

GF

J-.

I, L$ =

/%.

E /)

#

E /) #

5% !

O)

#

() * + , -

/ + , -. !" * / -. /%. /K

4

A

" " ( U 0 !"

1?- A

*)

5" #

O)

#

O) !"

#

/8 M #

O)

O)

1,

" "#



5

(

I"

O) E*%"/& 5

1"

( ,%

(

P8

4S

*, #

O) !" E ,%

E* I"

" E ,%

#

" " ,D

O) (

I"

" A 1,

,D A

#

( 5

O) !"

#

(

# "

3

&T #

O)

A

$( 1* %2

,

W

-

%)

" !" #*) V" 70

1

B

O) ( #*) V" 70 -

A

E ,& !"

,D V" 70 /

X"/

5

,) 1,

4

I"

I"

/ 0 1 %2

"#

,D

1?- /)

J= .$

A

GN

5 -. !"

U 0

" !"

" "#$

1?- 5" R K

! P8

%&'

(* "PQ8

/8 M L$ = E*% 1,,70 * / -. !" /%. #*)

!

M &

%)

/Y% E ? /8 M 1,2

,D

( ,%

.$ /0 * 1, ,70 #

%) !" Z ,) (

J8

(

" "# %) 1,

O) 0 *% " J8

/2 M *"*

[email protected]

.

+ , -. /)

5

( *)

/8 M

W "

3( 3( 4*%

WWW.IRANMEET.COM

5 "\

( -

W

T, ( \

# -

( M 1,

,&

(

%) ./-I !"

;, C

%) 5

5

%)

5

1,2 (

( 1" ( 1"

" "

./-I 1" *%

" I"

4 /) #

\

A -0 K

X[ E /)

* "

#*"

#

$( $ %

]

*%

#

\

$/K

*)

%)

#*) I"

W A/\

)#

\ 1 M 1,

Z ,)

E*%"/& 1"

I" K/

\

5

" "

./-I

(

]

"567

"

-"

E*%"/& . $ / 0 ./-I E /) ,Y%0 ( I" 1 ?- #

I"

"

Z,)

" "

,^ 7M / / / "

>.

I" 1,2 E(

1, E*%

+

+ C ]

+A J= * /) ;, C

*%"/&

]

;,C 1"

`

" A -0

- ,D0

5

(

, ,D _

" (#

1,2

Z ,)

A

5

' " ' ;<$ 3= > ?@

"

5

* #*) V" 70

( ( A 5% "

() C7

;M

" ]

,^ 7M / 1 M 1,

!. $ / 0 . I"

: 2 8 #9

./-I

;,C

(E

&

( ^( *% ,D0 "

.$ /0

./-I % 0 . $ % 0

( "

( 4% 0

B 4" E*%"/&

%0 ( ( A 5%

^( * /)

V " 70 U 0 J8

#

"

U 0 & $? [

%) /-

E*)

/

E*%"/& C

.

5 C ,B ]

;,C

D.$ /0

./-I L

;,C

E* /) -

C T,B .

;, C

/ -. ;, C 4 / )

&

W

*

#*) I"

.$ /0 5

( ./-I E

`*7 C W_E*,% a

[email protected]

]

I"

;,C 4*) #*)

!% ]

8 #9

(

;,C ] / "

C ,B E$ =

WWW.IRANMEET.COM

program

main ();

.$

/0

L C ]

;,C

L C ,B ]

;,C

sub 2

var A , , B , C : real ; procedure sub 1( A : real ); var D : real ; procedure sub 2 ( C : real ); var D : real ; begin

C,D A , sub 2 in sub1 , B , sub1 in main

.$

/0

L C ]

;,C

L C ,B ]

;,C

sub1 A , D , sub 2

C := C + B ;

B , C , sub1 in main

end ; begin

!

main

sub 2 ( B );

.$ /0

A , B , C , sub1

end ; begin sub 1( A ); end .

b /8 " 1, %6

" ` *,

(*

#*) V" 70

" (

,[

5

_P 8 + - *% E*%

C ,B ]

/-. ]

;,C

%)

c7

(

" $? [

*% *% #

#*) V" 70

,[

]

;,C

;,C ZT C ,B ]



' 8 #9 E A \

" K

"

LF ?

;,C

LN ?

.$ /0

\ d" W I" (* * /0 T,

*%

−,+

,^(

, -.

F > G* + <.

E* J,? 0

/

\%[ A/ \ J

#

( 4

#

f

]

;,C

H

4*) #*) 1,,70

$ 2

- 3

x

&

#* "

f

5"

J 3f

"

( ( 1,2

%)

#

" O) !"

"

%) /)

x

%) 5

x

5

(

& ( 5"

3( e B 4 E*% V" 70

#

O) !" ( #

*,[ ;,C

%) 4 M &

]

;,C !" (

%) !" E*

0 /W

*)

"(

C ,B 4 C * /0 *% *,[

:* ,

"(

%) !"

]

C ]

;,C

C ,B ;,C

[email protected]

%) 4]

% $

*

0 , -. ]

+ , -. !"

& 1%0

%) 4] + ,-. &

" "( DH%0 .$ + , -. & L% 0 1%0

D

WWW.IRANMEET.COM

A %)

/

5

(

"

,^ 7M

./-I

"/[ # /2 !"

5

(

4

/%.

E*%

*%

V" 70

"/[

, "/[ # /2 #*. 3 4

f ; /0

5"

J )

#

" J )f

/8 M

/)

f

%) !"

"

;,C

- 3 /%.

5

(

" ; /0

(

"/[ # /2

1,2

%)

Y

A

"/[ # /2

x

I*

5

]

/8

/8 M

/ "

( ( 1,2

,^ 7M

A

J 3

^2e 2

#*) I" f

G1

#*

E f M$ =

I

5

I

G

( !" ,%

#(>. x 5

(

"/[ # / f

5"

&

2 ( /)

"

/8 M

E /) " T, (

#

/8 M

" 4 f /8 J ) 4f

f

EEE ( *) 5

((

%) ! " V" 70 1, 5"

f ; /0 #*)

,0 !"

"

,^ 7M

/8 M

"/)

/

#* . 3

&( (

/ (

" # / 2 #* . 3 (

f

]/ ( x 1, *

>.

]

E *%

# ) J8

q

B

F

f

x

>.

" V" 70 /8

5

x

#

( !" x

" " x

F

"

" ; /0 #*)

,%,

,D ]

# )

*% "

q

"

1

x

%)

V" 70 !"

1,,70 B

x

(

"/[ # /2 #*. 3 ^( *%

" #* . 3 ( 1, *)

?"

/

1

1" $ #*" # /- *

>.

" !" x

%)

>. ;

#*) 1,,70 5

*) #*

^2(

N

" + /W

*

U3 (

>. !"

`

$=

/%.

>. I q

& " ( *) /K

/8 M_

%7" E*)

) J?

"

" # /2 1,,70

" # /2 #*. 3

E

[email protected]

/ (

( N J8 >=

] 1,2

(

I

" # /2 #*. 3 $ ? [ EEE J8

]

/8 M 3(

1

%) V" 70 f

*

T, "/[ # ,I

E # /2 /)

/

5 / (

&

^ 2 1"

( "/[ 3

WWW.IRANMEET.COM

program main (); var x , y : integer ; procedure R;

procedure P; var x : Boolean ; begin

& '#" , -,

var y : real ; begin

Q // call Q

x := x + 1;

end p begin main p;

var x : real ; begin

end .

1

0

. % 8 2

x #$ %

. %

?

9 -, R 0

0( 1 0( > & 0 (

@A2 3

$

:

( G (4

1

3 + 4

0 +

B6

6 0? )

K

< 1 (+ <

1 + ,

'

6 $

" ,

. % 8

!

BC

1 5 67 (

?

F 0 = DE 0 +

( ! ,9

!

R -,

%

6

" + ,

1 5 67

BC

":C

0 +

0+

0

1 01

% !& !

0 %%

;

&

)

(

2(4

' (# " 0 %

1

. 0 +

0 %%

%

&%

6 0?

"# $ !

% !

3J% % %

,)

& !

L+

! 0 + ,)

! J%

M $ 0 1N4 0 0

1

67 BC

*$+ 0 "

.

D"0 +

: 7 #

2A %

7 "

J% % & O + 0 + 0 J%

% %: 7 + ,

[email protected]

"

Q+9 R +

"

* + ! %

&-. + !

C % pascal , Lisp , Ada

<

x

@A2

< (

<

"

% $

H :? I

'

S % BC

# $ % 0 x0 > &

x

. % 5 67 ! 0 +

(4

"

x

& )

(" (

#$ %

x

<= main ; BC

2(4

2+ 5 67 R -,

" 2 % <= ;

end Q;

(

R . %

<

R; // call R

(

4

(

" ,

x 3 -, 0

& ' #( "

"2 3

(

Real > +

" #$ %

x := x + 1

#$ %/"0

9: 7 R 0

end R; procedure Q;

!

# $( % ) *+

x

x !

(

+

%

pl / 1 % Alg ol , %

, !

* + ! (

2A 0H

P0

1

WWW.IRANMEET.COM

+ (,

U(

D"

)?+

TN J% < 1 .

0 (V X(& TN( J% < (

0

BC

(7 )%

3 +

SW V0

1 .

! U

=0 +

24

"0 +

J% TN J%

B*

6 0?

L" ; #

( 0(

1 01

&% Z 2 W FP

W ( FP 0( (" 0( +

(

7

U "0 +

"

H

&

0Y

D &

/ 0 1 23

4 5(#

0

9

\ P QG 0 E L6 < 1

[

(+

(1 0 (1

1

] V F

=Z 2 : C ; Z 2

" ,)Explicit&6 7 "8 9 5(#

0 +

7 )H

02 L"

0 1 N4 Z 1 0 " 0 +

< 1 01 (" MF(

Common

" Z B % C++

_ , -^ ,)Implicit&":;< "8 9 5(#

Maxint F^

)Dynamic scope&

; =

"82 ! > ' (

a (1 ) (? + (Q+9

Q& 7 )%

( \ P

J% 3

"0 +

# H

"0 +

"

C "'!

!

8 ( 4 ( < 1

< 1 ( ( ) ( (^

y% x ( ( + 0((( +

" 0 +

! ?@

' A "'!

24

((

0 Q+9

% "

U

: ( A(:%@ B "'! b1 U ,D

K 7 0 +

G GF

E!C

? , F(

: 70

( (1 ,) ! G G7&

( (1 5((( 67

?@

"0 +

%K 7U 0 0 1 + ,

4 5(#

) ? + U H7

, 0 +

;

U ,/ 0

` *7

W FP U H7 < 1

0

,-. + ! ( < 1

(

+ ,

G G4

! GG

procedure sub( x : int eger , y : boolean)

<

1 5 67 9

sub(i,j)

0(

(

(.

("

j % i -^

( 0

0 9

6 %

3" # = ! ;

0 + 0 + "

+ , *$+

' .+ "

) ? + U H7

< 4 (

( % 0(

(6 %

(

(% 3

.

% 0

6 %

%

' .+ 6 < + 1

[email protected]

.

<0 H+

b1 , )";'! H" 7 &"?

0 4

b1 U

!

0

J% % 0 E L6 c 7

,I(?

J :@

1 #+ <<< %

.

WWW.IRANMEET.COM

*$(+

.

"

0

BV

"

C V0 + sub( y

B,x

J%

27)

Ada

4 % $( 7 (" <

*$(+

(&%

BA d P0 +

1

$" T% 6 =parametr passing; "

= (6 %

C; 6 %

(.

(

!7 " %

L+

"

9 0. + % (f

) H(

(6 %

< (1 ( h $(C

0 +

4 9 5 67

6 %

!

0

6 %

? J%

'

&

-* var

B 0LB

g% , ' # "

?

0

QG -(

< 1

.

"

. %

_7/" " > M e

< 1 D Q+

.

6

" > M e

,)call by result& F(

? 0 +

1

4 KN( %

"

+ 6 %

J%

"

'!

1

+ ,

C

"

L

J :@

-^

,)call by value&! L

f U J%

U 0 +

.

"

!

" J% 0 0 J%

!7 6 %

' .+ W BL

("

.

)?+

? <

(

*$+

,K

+ ,

U -,

. ? X7 7

0

1

0. + < 1

iG

? J%

(.

" 0 >&

( 0( 0(Y 0( +

( j 0(

(

+ (,

"0 +

-(C 24

) ? + J% -, (.

7 )%

< 1 (

%0 +

.

= 6 %

( !7 (" 0YC "

g% ,

> (+ ( C (

,)call by Reference&$ ! " > M e

J% f

(

%

%

1

M 9; 6 %

h $C

Q+

4

)L = 6 %

"2 -

6 %

%

(" ( < 1

L" Algol ; 1 ( 0( 0( +

( 0(6&

?

>&

4

call by Reference

7

1 01

(

+

R +

.

%

"

) 6 'l + H "

0 0

O +0 + sub(y)

) H

"

1)L W

1 ?

<

+ ,

J% 3

" > M e D &

1

4 " ,

.

9

c

" A 4 procedure sub(x:intege) . %

%'+

+ ,

& 0 sub ) % 0+ R +

Y+

0 4

6 % <) ^ 0+ 4

W Vy < 1

[email protected]

,

1

DE

4 " A+

y " x 0L"

+ ,

!7

k)call by name&K G

"

0 >&

" 4

L J%

7 6 %

BV 0 +

U( y 0( 0(6& 7%

"

6 %

?; 6 %

< ( =

%9

. %

"

WWW.IRANMEET.COM

0( +

&% ,

06m 0 0& 7 < +

1 5 67 call by name W V 0 "

49

=poeno 7 f

program example; var A : Array[1...10] of integer ; I : integer ;

7

!7 > &

+ ,

" ! 0

procedure Exchange ( x , y : integer ); var temp : integer ;

0

begin temp ← x; x ← y; y ← temp;

J%

+ ,

?(

+ '+

< 1

-* '#"

Exchang ( I , A[ I ]); output ( I , A[1] , A[ 2] , A[3] , A[ 4]);

J% <%

)L

0

BV 0 +

< + 2 q 67 " 2% 4 X 7 7

+ , + ,

l G 0G

" !

' .+ A[2] ← 4 h $ +

end ; Begin (main )

<) ^

+ ,

( %

2(4

0 +

Q ;< 1

2 ' .+ " ) %

6 A[I] % I

I ← 4; A[1] ← 8; A[ 2] ← 6; A[3] ← 4; A[ 4] ← 2;

L7

4

I

I

A[I]

4

A[4]=2

x←4

y←2

2

24

-*

x=2

y=4

24

6

I =2

A[2] = 4

G

End .

= + A =call bye name;' + : 7 + ,

J%

0 iG ; 2, 8, 4, 4, 2 d 0 +

&% ,

i

+ ,

begin j := 2;

+ ,

1 j 5V 7

-* '#"

x := x + 1 output ( y );

S [1] :=' A' ; S [ 2] :=' B ' ; S [3] :=' C ' ; i := 0 ; j := 1;

# Y+

0 + <) ^

s=nre 7 f

var s : array[1...3] of char ; var i j : integer ; procedure P ( x : integer ; y : char ) var j : integer ;

output (i ); end ;

? 3

&% , O

0

S [1 + j ] S [ 2] = ' B '

x←0

y ←' B'

24

-*

x =1

y ←' B'

24

6

i =1

S [ 2] = ' B '

! 0 S[1 + j ] W * < 1

P (i , S (1 + j ) ); output (i );

[email protected]

Q; $G

t G i =1

? < 1

j0

BV 0 +

1 0& 7 <0 H+ %<

' B' , 1 , 1 &% ,

WWW.IRANMEET.COM

(6 Global % List[2] 3 List[1]

(?

1 ' + )% 0

) ? + J% <

procedure bigsub; Integer Global; Integer array List[1..2];

4 3

G iG 0

# Y+

0 + <) ^

X7 70 0 +

2 3 5 3 3 iG 0

&
procedure SuB( param); integer param; begin param := 3; Global := Global + 1; param = 5; end ; begin List[1] := 2; List[2] := 2; Global := 1; suB( List[Global ]; end .

) *7 'l + H 0 <=pu e 7 f

Q;

'

program main; var k : integer; procedure XYZ (i, j : integer ); var k : integer;

7 V

0 +

&% , <) ^

1 call by name , call by refrence , call by result , call by valu
begin i = 300 ; k = 2; if i = j then j := i * k + j; end ; begin k = 100; XYZ ( k , k ); write (k ); end .

[email protected]

WWW.IRANMEET.COM

&' ( ! $



%$# ! " ! "

garba 6

%-51

4

2 3

-

. /

0

-1

# $!

+, -

!*)

% #

% & '()

" ) & * *7 ; .:

+ () ,-. + ? ' @ $% F G

>RAM=

+< 1

89

B+

: ;9 #

% 1 ! $ C 9

89 2 +3

(.

0 89

D 1

! E A Fortran HI

(*/ 0 ) ! / 5

(

(+ @

- 89

# + 89

! $

89

1 N 0

%

O - 5 JK 9 E P#

%-51 N $% E9

89 B

Head G

%-51 D B.



%$NS 4

+< 5 JK

T

CL '

$% $ ( +

: 0-

C

OQ #

Heap 0 )

M (N

# + E P# + 5 JK 9 %

+ 51 U

.

!

*7

Q- ! V3 9

& 4 5 64 " # $!

0X SO

GW

U . #

! " ! + 23 ) V

L !

RC # +

%-51 0 , -

-

(.

+ 2 3 Heap

% + 5 JK

4 : L ' Heap 89

*)

,B *Y ( 8 2# *)

- 5 1 - 9% V2!*7 -

.

7

41

[email protected]

- $) ) 83*

89 -

WWW.IRANMEET.COM

Alloc Elem Set ( p );

!

p=q

Garbage*Y

Int * p,*q;



%$+

% O

U . #

%$p 0+`

# 4 ( 4

q = malloc ( size Of (int)); p = q;

- !

: 9

h

< = , > - *)

int * p,*q; p = malloc ( size Of (int))

% - 5 1 aF!

q = p;

b

0 + . #

%$h % : q V3 9

p,q 0

0. /

+ 2 3 V3 9



%$(+ 5

p $ 0 free

9

, _

free( p ); ;

5 + 23 HI . #

Dispose

\C $ U

, 25 89

%

$

0 GK[ Z

B

S!

Z

L

0

%

L

. /

+

89

+ c$

+ 1 B N

(.

free9 E U C

+ ]3 H [ $ 25 $ H [

+U 0 1

,= + 5 B. # ^F

( .

2#

9: A

0

,

B

B . 2# B . #

6

%-51

4

J

: &' ( D

9. #_

O .

= ?- @4 ? -

Refrence counterG + 6 - 1 : heap J

O

@

, N0 ,

+ 23

`

2#

9-

SO

U . # J

9: .

% - 5 1 aF! 1

5-

.

:

0

2# $% - % 9

2#

$ # / L

F5 +49 # V + ]3 HU, 9 0 1.) + 23 (-

J >: =

5

N#

5 on 5

> , / = #

89

6

25

#

b

e N U H2[

, off S % >G.C.B=d(

%-51

4

;!

9

4

39 c 5 +49 89

C/ ,-.D $: : g 3 f 5 KI

]20 $ 0

J

# ! #

1 0$

[email protected]

:

5 Active -

[ *Y

5 5 d( L 2 (

: -F

42

. ! 89

? ' @ >d(=

2 3 0

E "- B@ S,C

(N5

N5

+ 5

5

" # "- A B@ ? -

# 4 ( 5 4

. # $% :

%$)

>+

9

$ C

) 7 ? -F 5 0

_9 (= +

RC*)

(3: G2 E9 . B

. 9 : G9 . B

Page 1 Programming Languages Design and Implementation ...

Include. C. ) software simulation. : (. ) .... software simulation. (. ). 24 я я я ...... SiP j i. C. SB. SA. S end i output y output xx j begin integer j char y integer. xP ... Global param begin param integer param. SuB procedure. List array. Integer. Global.

2MB Sizes 1 Downloads 285 Views

Recommend Documents

Return-Oriented Programming: Systems, Languages, and Applications
systems, has negative implications for an entire class of security mechanisms: those that seek to prevent malicious ... understood that W⊕X is not foolproof [Solar Designer 1997; Krahmer 2005; McDonald. 1999], it was thought to be a ..... The remai

Design and Implementation Statewide Pandemic Triage Line.pdf ...
Page 3 of 9. Design and Implementation Statewide Pandemic Triage Line.pdf. Design and Implementation Statewide Pandemic Triage Line.pdf. Open. Extract.

Relational Database Design and Implementation ...
[Read PDF] Relational Database Design and ... administration, this book provides practical information necessary to develop a design and management scheme ...

database systems design implementation and ...
database systems design implementation and management 10th edition contains important information and a detailed explanation about database systems ...

[Read PDF] Database Systems: Design, Implementation, and ...
In-memory databases emerged in response to new application 7 Course Objectives Gain understanding of fundamental concepts of state-of-the art databases (more ... Online PDF Database Systems: Design, Implementation, and Management, Read PDF Database S

Design and implementation of Interactive ...
Processing can be deployed within the development environment, in Java projects, as well as in HTML/JSP pages in tags. For web pages integration, processing.js extension is needed. Its main purpose is to translate the whole sketch into the Javascrip

Page 1 Page 2
Page 1. Page 2.

History-Of-Programming-Languages-Acm-Monograph-Series.pdf ...
Retrying... Whoops! There was a problem previewing this document. Retrying... Download. Connect more apps... Try one of the apps below to open or edit this item. History-Of-Programming-Languages-Acm-Monograph-Series.pdf. History-Of-Programming-Langua