SHARE |
|
by Bill Degnan - 11/10/2008 08:56 | |
A modified version of the program found on page 7 of the Waterloo Pascal manual that will send the output to the printer.
program example5(output); var x,xsquared, xcubed;integer; p:text; begin rewrite(p,'printer'); writeln('A table of squares and cubes:'); x:=12; while(x<=21)do begin xsquared:=x*x; xcubed:=x*x*x; writeln(p,'A table of squares and cubes:'); writeln(p,x,xsquared,xcubed); x:x+2; end; end. [if this does not work for you, contact me for assistance] Reply |