home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Computer Buyer 1996 March
/
buyer-0396.iso
/
thompson
/
vincent
/
product
/
sinus.pas
< prev
next >
Wrap
Pascal/Delphi Source File
|
1995-09-11
|
667b
|
34 lines
program sinus;
const
nom_fichier='Sinus.txt';
fin='FIN.';
polygone='POLYGONE';
finpoly='FIN_POLY';
var i:real;
x,y:integer;
script:text;
begin
Assign(script, nom_fichier);
{$I-} Rewrite(script); {$I+}
if IOResult=0 then
begin
writeln(script,polygone);
i:=0.0;
repeat
x:=20+round(i*20);
y:=100-round(sin(i)*40);
writeln(script,' ',x:4,',',y:4);
i:=i+0.1;
until i>=4*pi;
writeln(script,finpoly);
writeln(script,fin);
end;
close(script);
end.