A practical introduction to Pascal programming language - GIARA
A practical introduction to Pascal programming language - GIARA
A practical introduction to Pascal programming language - GIARA
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
Iterative constructionsProgram 67: Exercise 3.27program c03e27;constMAX_INTEGER=32500;varn:integer;prevInt,prevPrevInt:integer;counter:integer;beginwriteln(’Please input the sequence of integers ended by zero (0): ’);prevInt:=MAX_INTEGER;prevPrevInt:=MAX_INTEGER;counter:=0;repeat(* 1- Reading the next value *)read(n);(* 2- Updating the other variables *)if ((prevPrevInt