pascalabcnet/TestSuite/CompilationSamples/Proc3.pas
Бондарев Иван e6e67c193c initial commit
2015-05-14 21:35:07 +02:00

26 lines
409 B
ObjectPascal

// Óïàêîâêà ïàðàìåòðîâ â çàïèñü
uses GraphABC;
type
Point = record
x,y: integer;
constructor (xx,yy: integer);
begin
x := xx;
y := yy;
end;
end;
procedure Line(p1,p2: Point);
begin
GraphABC.Line(p1.x,p1.y,p2.x,p2.y);
end;
begin
var p1 := new Point(10,10);
var p2 := new Point(10,210);
var p3 := new Point(210,10);
Line(p1,p2);
Line(p2,p3);
Line(p3,p1);
end.