การเขียนโปรแกรมเพื่อใช้งาน (programming for...
DESCRIPTION
การเขียนโปรแกรมเพื่อใช้งาน (Programming for applicationsTRANSCRIPT
1. Each of the followinmg represents an attempt to write an
algorithm that computer the sum of the first 10
integers. State why each is either poor or invaled.
(a) START
set sum to 1+2+3+4+5+6+7+8+9+10
write sum
END OF THE ALGORIOTHM
(b) START
set n to 10
set sum to 0
add n to the sum
decrement n by 1
set if n > 0
if it is go back and repeat the previous step
write sum
END OF THE ALGORIOTHM
(c) START
set i to 10
set sum to 0
repeat 10 times
add i to sum
end of the repeat loop
write sum
END OF THE ALGORITHM
4 0
(d) START
s e t i to 1
se t sum to 0
while i c 10 do
add 1 to sum
increment i by 1
end of the while loop
write sum
END OF THE ALGORITHM
2. W r i t e a va l i d a l g o r i t h m t o f ind the sum of the first k
i n t e g e r s l,‘Z,...,k. t h e v a l u e of k will b e e x t e r n a l i n p u t
t o t h e a l g o r i t h m . ( B e sure t o h a n d l e t h e ilegal s i t u a t i o n o f
K <= 0)
3 . Wri te an algorithm t h a t ditermines t h e m o d e o f a l i s t
mode is the value that occurred most frequently. For example, in
1 2 2 3 3 3 4 5 5 6 6 7 7 7 7
the mode is 7 and has a frequency of 4. You may assume that
(a) The values are has already sorted into ascending
sequence.
(b) If two or more values occur an equal number of
times, the mode will be defind as the numerically
1 argest value. The algorithm you develop should
n o t s t o r e a l l t h e d a t a i n a l i s t ; i t s h o u l d r e a d
in only one value at a time and process that
value. The output of your algorithm should be
the mode and its frequency.
4. Develop an algorithm to solve quadratic equations of the
form ax2 + bx + c = 0 using the quadratic formula
Roots = mb - b - 4ac* P - - - - - -
2a
YOUI- algrithm should handle the regular cases as well as the
special cases of;
(a) A double root (b' - 4ac < 0).
(b) Complex roots (b7 - 4ac < 0).
(c) A nonquadratic equation (a = 0).
(d) An illegal equation (a = 0,b = 0).
5. Assume that you are given a string of input text of
arbitary length and ending with a "$". Furthermore, assume
that you wish to print this text as a set of line of width
no greater than k columns (k will be external input to the
algorithm). The rules of our printing alSO specify that we
must never break up a word between lines (Assume the length
of one word ) will never exceed k ) If a word cannot fit on
the current line , print the current line, print the current
line as is and go to on to the next line For example , if
5 2
nlvnFlJLioL5luvfl modu 1 e dW~WWl?&li? Ql71tuvlfJ~lvat
74
begin
writeln('in p2:', x:3,y:3,a:3,b:3,c:3,d:3)
a:=ord(b)
end;{of p2]
begin[pl}
d:='x'
writeln('in PI:', x:3,y:3,a:3,b:3,c:3,d:3);
x:=y;y:=O;b:=chr(a);c:=chr(x);
p2;
writeln('out pl:', x:3,y:3,a:3,b:3,c:3,d:3)
end;{of pl)
begin {program block}
a:=l;b:=Z;c:=3;
pl(a,b):
pl(b,c) i
pl(c,a)
end;{of block]
6. Assume that we had a procedure that merged two sorted
listed a and b procuced a!new master list c containing all the
elements of both a and b. The parameters to the
procedure are:
87
d e c l a r e v a r i a b l e
startd e c l a r e v a r i a b l e
let x = x+1
Write X
end o f ~roc~ram.
w-i te X
ii:End.
b . s e l e c t i o n
b.1 if then
F
i f ( c o n d i t i o n ) t r u e
then do task A
e n d o f i f
do task B
program ex3(output);
var
low, term : real;
sign, n : integer;
begin
logn := 0;
sign := 1;
n := 1;
term := 1;
writeln('n logn term’);
while(term >= 0.0001)
do
begin
term := 1.0/n;
logn := logn + term*sign;
writeln(n, logn, term);
n := n+l;
sign := -sign
end {end of while}
end.
1 average = sum/howmany
1 0 8
50 FOR I = 1 TO 10 STEP .5
100 NEXT I
3. nis'l.ii nes t ed f o r l o op finh-rLnn r-h
3.1
10 : for i := 1 to 10 do
begin
f o r j :=l to5do
begin
end;
i f ( c o n d i t i o n ) t h e n g o t o 1 0 :
end
for i
begin
program exfor...
for i := 1 to 100 do
begin
end
111
Which Loop Primitive Should I Use?
In this chapter we have introduced three statements for
p e r f o r m i n g i t e r a t i o n i n P a s c a l - - t h e w h i l e , r e p e a t , a n d f o r .
You w i l l need to choose the appropriate one when you begin
w r i t i n g YO”I- programs. In many cases it won’t matter , but
these two guidedlines can assist you in making the r i g h t
choice.
1. T h e f o r l o o p i s t h e l e a s t f l e x i b l e s t a t e m e n t
and s h o u l d never b e u s e d w h e n there a r e t w o o r more
c r i t e r i a for loop emination. Y o u w i l l g e t y o u r s e l f i n t h e
f o l l ow ing b ind .
{loop can terminate after 100
iterations or upon encountering a negative value}
for i := 1 to 100 do
begin
readln(x) ;
if x < 0 Then ????
else
{ p r o c e s s t h i s d a t a v a l u e }
end { f o r l oop }
What do we put in for the question marks? It will have to
be an unconditional branch. If we had selected a while
o r repeat ( the l oop termination conditions could have
been phrased as
1 1 2
while (count C= 100) and not(x c 0) do
2. When choosing between the while and repeat
take a carefule look at the null case -- the situation in
which there are no data to process The repeat loop will
alWayS execute the 100p today at least once and may not
correctly handle the null case.
1. Required punctuation missing
2. Unmatched parenthesis
3. Missing parenthesis
4. Incorrectly formed statements
5. Incorrect variable names
6. Misspelling of reserved words
syntax e r r o r ,J~rlnn~i~niln~an~~~~ (interaction)Y
~~oJfl~~Jn~o~lnnillul~ ~J$%atilJa=i4u
1. Conflicting instructions
2. Nontermination of loops
3. Duplicate or missing labels
4. Not declaring arrays
5. Illegal t,ranr;fer
1 3 8
146
Loops
1.
2.
3 .
4 .
5 .
Data
1.
2.
3 .
4 .
Variables
1.
2.
3 .
4 .
N o t i n i t i a l i z e t h e l o o p p r o p e r l y .
Not terminate the lopp properly.
Wrong number of loop cycles.
I n c o r r e c t i n d e x i n g o f t h e l o o p .
I n f i n i t e l o o p s ( s o m e t i m e s c a l l e d c l o s e d l o o p s ) .
Failure to consider one or more conditions.
F a i l u r e t o e d i t o u t i n c o r r e c t d a t a .
Trying to read less or more data than there are.
E d i t i n g d a t a i n c o r r e c t l y o r m i s m a t c h i n g o f e d i t i n g f i e l d s
w i t h d a t a f i l e d s .
Using an uninit ial ized variable.
Not resetting a counter or accumulator.
F a i l u r e t o s e t a p r o g r a m awitch c o r r e c t l y .
Using an incorrect variable name (that is , spell ing
error using wrong variable).
Arrays
1. F a i l u r e t o c l e a r t h e a r r a y .
2 . Failure to declare arrays large enough.
3 . Transpose the subscript order.
1 4 9
Semantic Error
These errors are caused by the failure to understand exactly
how a command work::. An example is to assume that arithmetic operations
are rounded. Anot~her example is to assume that a loop will be skipped
if the ending valu~e is smaller than the initial value. In IBM FORTRAN
00, loops are always executed once.
Semaphore Bug
This type of bug becomes evident when process A is waiting on
a process B while process B is waiting upon process A. This type of bug
usually emerger; when running large complicated systems, such as operatin
systems. This is called the deadly embrace.
Timing Bug
A timinS bug can develop when two operations depend on each
other in a time sense. That is, operation A must be completed before
operation B can start. If operation B starts too soon, a timing bug
can appear. Both timing bugs and semaphore bugs are called situation
bugs.
Opration Irregularity Bugs
These bugs are the result of machine operations. Sometimes
unsuspecting programmers do not understand that the machine does arith-
metic in binary; so the innocent expression
Task Units
Planning 1
5 . Pr
insert, delete
ulJ%l~flalualul:
alul5fl~Lfla‘Lunl:
“151\
Writing
Debugging
Testing
160
? 100
index fibonacci number
0 1
1 1
2 2
3 4
4 8
5 16
6 32
7 64
8 128
end of the fibonacci sequence
a total of 8 numbers were generated
(a) Insted of printing out 100 numbers as we had requested,
the program only pi-inted out 8. In addition, the numbers
did print are incorrect, Discuss how you would go abo
finding and correcting this logic error. In your answ
discuss the role that hand-simulation, the program outpu
and additional writeln commands would play in helping y
correct the mistake.
(b) After correcting the error(s) from part a, test the
program to see if it works property under all possib
conditions. if not, suggest necessary change to make t
program more secure against pathological conditions.
D E F I N T I
D A T A “B”, 4 0
READ NAM$,IVOL
= IVOL **I
ANEXT I
1 8 4
1
2
100 2nruuuufiaz.Pizlnn
67 a2 69
43 65 72
56 76 74
sex : 1: %lU
2: MGJ
age : i n t e g e r 2 Gn
per : 1: ‘Sal.
2 : -Iha,
3 : 6QU+-
I
2 0 4
uuuii 1
Btype .__ . . . . . . . .
var . . . . . . . . .
205
task1 : decisl[l,l ] :=: decisl[l l]+l
t a s k 2 : decisl[l,Z] := decisl[l,Z]+l
t a s k 3 : decisl[l,3] : = decisl[l,3]+1
t a s k 4 : decisl[2,1] := decisl[2,1]+1
t a s k 5 : decisl[2,2] := decisl[Z 2]+1
taskR : decis1[2,3] :== decisl[2 3]+1
end
readln(age,per)
/decisl[sex,per]:= decisl[sex,per]+l
2 1 3
2. reduced representation form
1 J 1
2 1 3
A 4x3 5 1 7
5 5 -22
14 5 a2
4 3 1 9 7
5 1 5 0 2
8 9 0 7 5
2 7 2 5 14
1
4
5
R
2
3
1
9
7
5
0
2
7
5
14
- name A 20 element array of character
- year in school : An integer between 1 and 4
- Grade point average :real
- Fees Paid : boolean
type studentrec = record
name : array [l..lO] of char;
year : 1..4;
!3ra : real;
fees : boolean
end.{student)
var
student : array[l..ZO] of studentrec ;
s.tudent[l]
name[l] ._ name[lO] yearname[l] ._ name[lO] year gra feesgra fees
student[ i] := student [j]
student[l].name[l],...,student[l].name[l9]
studant[l].year
student[l].gra
student[l].fees
a .
with student[l] do
begin
for i:=l to 20 do
read(name[i]);
year := 1;
9ra := 4.0;
fees := true;
2 2 0
1. Show the Pascal representation of the following constants.
*(a) .a
(b) e (the base of the natural logarithms)
*(c) the fractional value l/2
*(d) 6.02 * 10z3
(e) the number 7
*(f) the character 7
(g) the color red
e(h) 18 billion
(i) truth
(j) the blank character
2. Which of the following are valid Pascal const
declarations? Identify the error(s) in each of the invalid
declarations.
(a) const
highvalue = 200;
(b) const
lowvalue = 0 or 1 or 2;
(c) const
firstchar : 'a';
(d) const
greatest = 200.0;
least, = -100.0;
(e) const
range = 200..800;
2 2 2
Cc) var
a : integer;
b : integer;
c : integer;
abc :real;
( d ) “ar
resulta, resultb:real;
count : integer;
C l :char;
X,Y :real;
6. Choose ressonable names and write B single var declaration
for the following values.
( a ) t h e t h r e e r e a l c o e f f i c i e n t s o f a q u a d r a t i c
equation
(b) the two real roots of that equation.
(c) a boolean value indicating whether or not there
was a solution
(d) an integer value that indicates the data set number
(e) the primary colors red, yellow, and blue
7. Choose reasonable names and write a single var declaration
f o r t h e following values.
(a) a six-digit student identification number
(b) year in school (freshman, sophomore,...)
(c) year of graduation
(d) grade point average (A = 4.0)
224
10. Look up the character code used on your computer and state
what the result of each of the following expressions would
be on your computer.
(a) 0x-d ('9') (b) chr(3)
(c) succ('z') (d) pred(ord('#'))
(e) chr(trunc(sqrt(517)))
11. Using the relational operators and the knowledge that
true ) false implement the following logical operators as defined
by the given truthtables.
(a) p=q(equivalence)
tb)
CC)
225
pbqtexclusive -or)
paq(NEGATIVE IMPLICATION1
226
12. Assign the following given value of three variables
a := 4;
b := -15;
c := 7;
d := red ;
What is the value of each of the following Pascal expressions?
( a ) ( ab s ( b -10 ) + a mod (c - l ) )
(b) a + 103 div sqr(a-c)
(c) pred(a * 6 + b div 5)
( d ) succ(d)
(e) (2 + a *b mod c + 1) < 2
13. Using the declarations from Exercise 12 as well as the
f o l l o w i n g n e w v a r i a b l e s :
x,y,r : r e a l ;
X: = 1.52El;
Y: = 0.3;
2: = -5.lE3;
What is the value of each of the following Pascal expressions?
227
(a) trunc(x *y + 1.0) a
(b) x/y ~3.4 +- z
(c) abs(sqr(sin(y) + CC%(Y)) - 0.5)
(d) round(x) div round(y + 1.6) + b
(e) exp(c - 4)
14. Using the declarations from Exercises 12 and 13 and the
following additional declarations:
"a=
m,n : boolean;
P : ch:Br;
m := true;
n :=false;
P := 'a'
What are the values of the following expressions?
(a) m and not n
(b) (a>b, and (b>c) or not(c = 7)
(c) not odd(c) m
( d ) (x,0.0) or (y>O.O) and(z>O.O)
(e) chr(succ(ord(p)))
15. Determine whether the following Pascal expressions are
a correct translation of the corresponding mathematical
notation. If not, add the IlC5CeSSaI-y parentheses to
correct it.
228
(a), I sin .5 - 1
cos t + 1
k := sqrt(sin(theta)-l.O/cos(thata)+l.O)
(b) ax*+ bx + c, k:= a * sqr(x) + b * x + c
Cc) a +c e I sqrt(a / b + c/d - e/f)
b d f
16. Translate each of the following English or mathematical
specifications into a correct Pascal assignment stagement.
Show the var declaration for all variables used in the
expressions.
(a) Taxable pay is gross pay less a fixed deduction
of $14 and less $11 for each dependent.
(b) The interest charge is 5% on the part of the
balance that exceeds $100 (you may assume that
balance >= $100).
(c) The average is sum of all scars
number of scores less illegal ones
229
(f) Valid is true if and only i f the examination
score is between 200. and 800.0, inclusive.
(17) Done is false unless x is negative, or y is
n e g a t i v e , orboth x and y a r e e x a c t l y 0 , i n
which case done is true.
17. Assume that we have the following data.
input pointer
II5 3 8 1 102
~601 0 8 0
1 5 Q 102
What values will be assigned to the integer variables a, b,
c by each o f t h e f o l l o w i n g i n p u t o p e r a t i o n s ? I n a d d i t i o n ,
show where the input pointer would be at the conclusion of
each s e t o f input o p e r a t i o n s . ( A s s u m e t h a t e a c h s e t o f
input commands i s independent and begins with the input
p o i n t e r i n the p o s i t i o n s h o w n . )
( a ) readln(a,b,c)
I(b) read(a,b,c)
I(c) readln(a);readln(b);readln(c)
i(d) read(a);readln;read(b);readln;read(c)
(e) readln;read(a,b,c)
230
18. Write the declarations and the input commands needed to
read in data prepared for the following format.
(a) A master payroll card containing a social
security number(integer) and a department number
(integer),followed by a separate timecard
containing hours worked this week (real).
(b) A single student grade card containing a 6 digit
student identifier (integer) followed by three
letter grades (a,b, c, d, e) all separated by
exactly one blank character.
19. Show how the data cards should be prepared if the input
commands in our program are written like this.
(a) read(x,chl);
read(y,chZ)
(b) readln(x,y);
readln(chl,chZ)
(c) readln(x,y,chl,chZ)
(d) readln(x);
readln(y);
readln(ch1);
readln(ch2)
23,
20. Assume that the variables w, x, y, L have been declared to
be of type integer and that the symbol ' ' represents the
end-of-file condition. If our input data is as follows:
input pointer
I13 80
21 Q
for each of the following input sequences, give the value
assigned to each variable and the value of the boolean
function eo'f on completion of the entire sequence Also
state whether or not the sequence would lead to an errc~r
condition caused by attempting to perform a read (or
readln) while eof is true.
*(a) read(w); (b) readln(x,y,r)
read(x);
read(y); (c) read(w,x)
read(r) read(y,z)
(d) readIn(
readln(y);
readln(r)
232
21. Assume our input was currently:
input pointer
I
Il ine 1 eoln next line eoln times up ,...
po in te r on comp le t i on of the input sequence. (Assume chl
and ch2 have been declared to be of type char.)
( a ) read(chl);readln
(b) readln;read(chl)
( c ) read(chl,chZ)
(d) readln(chl,chZ)
(e) readln(chl);readln(chZ)
22. Show the exact output produced by each of the following
output sequences. Assume t h a t w e a r e presently at the
beginning of a new line and that the referenced variables
h a v e t h e f o l l~owing v a l u e s .
x := 1.23456
y := 567 .89
z := 10
c := ‘$’
( a ) writeln(x,y,z);writeln(c)
( b ) writeln(x:15:l,y:8:3,z)
(c) write(x:15); write(y:15); write(c:3)
(d) writeln(x:16:4);writeln(y);writeln(z:l)
2 3 4
24. Write a complete Pascal pIWgI?Sl to input a data card
containing three values
(a) A real value corresponding to the amount of a
loan m dollars and principal).
(b) A real value corresponding to the interest rate
of the loan.
Cc) An integer quantity, N, giving the number of
payment periods per The program should complete
the loall payment required for each pay period
repay the outstanding principal in one year at
the indicated interest rate in N payments. The
for doing this is:
Payment = p(l + i) + 25N
where p = principal
i = interest rate
N = number of pay periods per year
$25 = annual service charge
The program should print out the input data and the answer in some
nice, format. NOW attempt to run this program on the computer
facilities available at your installation. If appropriate, run
the program in both a batch access and sharing mode. Familiarize
yourself with all aspects of the operations policy your computer
center. This would include:
2 3 5
Location of keypunches and computer terminals.
Operating procedure for keypunches and terminals.
Location of program submission stations.
Commands required for program preparation,executio
n, and stage.
Availability of consulting help and documentation.
25.Write the complete IJascal for solving this solutions to the
equation
3x + 2y 72 = 5
for values of x,y,and L inthe range Cl to 100.
26. Let vl and v2 represent boolean variilbles and let cl,sZ?,and
s-3 represent PaSCal statements Suppose that. ant: of the
statements is to be executed baszed on the values of the
boolean variables. as follows.
v2
t f
,vl t 51 s2fqs 3 s3
Set up a conditionals statement to achieve this effect.
236
27. Write a complete Pascal program to computer the average of
all legal examination scores. Alegal score is one in the
tange 0 to 150. You I‘ program should read scores until an
end-of-file condition occurs and then product as output:
(a) The average of all legal scores.
(b) The number of legal scores.
(c) The number of legal scores.
(Be sure your programworksproperlyevenwhen there ar
le$J7al Xor-es.)
28. The Fibonacci series IS defind as
II<, = I , n = 1
llj+:, = n, + nI., i = O,l,Z,
Thus, the fir-t few Fibonacci numbers are
1,1,2,3,5,8,13,...
Write a complete Pascal program to compute and print the
first k Fibonacci numbers, where k is, input to the program.
(Your program should work property even if k (= 0.)
29. Temperatures on the Celsius (or centigrade) scale are
relate on the Fahrenheit scale by the formula
237
Write a complete program that prints the Celsius equivalent
of Fahrenheit temperatures in the range low to high where
low and high are input to the program. The increment sire of
the table should also be input to the program.
30. Write a program that reads text and produces encoded text
by replacing each character with the character that occurs
five positions "later" in the character set.(Thus,
cnnsidering the typical ordering for alphabetic character,
'a' wouldbe replaced by 'f,' 'b' by 'g,' etc.)This
replacement should "wrap around" the end of the character
set so that there is a well-defined replacement for each
character. (That is, the character that occurs at the end
of the character set should be replaced by the character
i n the fifth position.You will have to know how large the
character set is on your computer.)Read text and print the
encoded form until an end-of-file condition occures.
31. Write a complete program that compute the minimum number
of coins and bills needed to make change for a particular
purchase. The cost of the item and the amount tendered
should be read as data values.Your program should indicate
how NlY3ny co 1 ins and bills of each denomination are needed
for change. Make use of these denominations.
Coins: $0.01,!$0.05,$0.10,$0.25 , Bills: $1,$5,$10
238
32. Write a program to determine the frequency of each vowel in
some English language text.The input will consist of sentences
running over a number of line. The end of the text is indicated
by the special symbol '*' that will not appear any where else in
the text. The output of the program should be the input text and
the percentage of characters that were equal to 'a,' 'e,' 'i,' 'o
'u, ' Blanks and punctuation marks should not be treated as
characters and should not be include in the total.
33. Write a program to count the total number of words in some
English language text. The input will consist of text
running ober a number of cards or lines. The end of the
text will be indicated by the end-of-file condition
becoming true. YOUI- program should count the number of
words n the entire input, whrer a word is defined as any se
quence of nonblank characters bounded on either side by one
o r more blank characters. (Therefore things like + 1.2,
real-life, don't,and l,OOO,OOO are all counted as one word.)
The output from your program should simply be the number of
words in the text.
34. The area of a circle with a radius of 1 is a, and the area
of a square thatjust contain the circle is 4. Therefore, if
a large number of points is chosen randomly in the square,
the fraction of those points thatfall within the circle
2 3 9
will be apprc8ximately s/4. Assuming the existence of a
standard real-valued function called random that returns
a r a n d o m number, r, between 0 and 1, write a program to
compute an approximation to d
35.Assuming randomnumber is a standard real-valued function that
return a random number, I-, between 0 and 1, write a program
that approximates the probabilities for rolling the values 2 to
12 with two dice.Use a case statement in the program.
36. Write n Pascal program to process the weekly payroll of the
Brooks Leather Company (BLC). For each employee of BLC your
program will compute the gross pay , deductions , and net
pay. This information is to be clearly printed in the output
along with certain summary information for the entire payroll.
Each week BLC punches a data card for each employee that
includes the following information. Social security number
(9 digests)
Hourly pay rate (xx.xx)
Number of exemptions (0 to 19)
Healt insurance code (1,2,3,or 4)
Hours worked (xx.x)
Using this information, your program should carry out the
following computations.
242
If S is greater than But No More Than Letter Grada
M +
M + 2 s.d. 100
1 s.d. M + 2 s.d.
M - 1 s.d. M + 1 s.d.
B
C
M - 2 s.d.
0
M - 1 s.d.
M - 2 s.d.
A
D
2 4 5
A f t e r r e a d i n g i n a n a m e , p r i n t i t o u t i n t h e m o r e s t a n d a r d
“ r e p o r t - o r i e n t e d ” f o r m a t .
ICCCCC ( cccc c.
f i r:;t 1 ast m i d d l e
name name i n i t a l
whe1.e ’ liist~ name and ’ f i r:;t-name’ i n c l u d e o n l y t h e f i r s t .
Rebei:ca Al 1 i son Schnc i der (. M e a n s b l a n k )
2 4 6
43. Palendromes. A palendrome is something that reads the same
way backward andforwaed. The unit in a palindrome can vary
Sometimes it is a letter (WOW or MOM) or a number (4884 or 121)
or words: STRAP ON NO PARTS.
(a) Find some integers N which when squared are palindromes.
26 = 676
(b) FIND some palindrome integers N which when
squared are palindromes.
22 = 484
(c) Generalize the above for powers larger then 2
(d) Write a program that is also a palidrome.
here is the example of a parlindrome
78
+87
165
+ 561
726
+627
1353
+ 3531
4884
Kingston H. Jeffey ALGORITHMS AND DATA STRUCTURES
Addison Wesley Publishing Company , 1991
Knuth E. Donald THE ART OF COMPUTER PROGRAMMING,
Addison Wesley Publishing Company , 1991
Schneider G. Michale , AN INTRODUCTION TO PROGRAMMtNG AND
PROBLEM SOLVING WITH PASCAL
John Wiley & Sons , 1982
98wulhiil... ~l~~~u~~~l~nula5l~~l~~~Ramlthamhaeng University Press.