Mám jednoduchý dotaz...
Můžu brát tohle jako simulaci sériovyho portu v Turbo Pascalu?

Kód:
uses CRT;
var h,z,d,q:integer;

procedure op;
begin
z:=h-d;
write('_');
if z>0 then write ('±');
if z<0 then
begin
write &#40;' '&#41;;
z&#58;=h+d;
end;
d&#58;=trunc&#40;d/2&#41;;
end;


procedure tisk;
begin
d&#58;=128;
writeln &#40;'Zadej cislo &#40;dekadicky, od 0 do 255&#41;&#58;'&#41;;
readln &#40;h&#41;;
repeat op until d=0;
writeln;
writeln &#40;'Znovu? 1-ano/2-ne'&#41;;
readln &#40;q&#41;;
if q=2 then exit else tisk;
end;

begin
clrscr;
tisk;
end.