program hodiny;
uses crt,dos;
var h,m,h1,m1,s,s1,stot,stot1:word;
procedure KurzorZap(ZapVyp:boolean);
var
Regs : Registers;
begin
with Regs do
begin
AH := $03;
BH := $00;
Intr($10,Regs);
If not (Zapvyp) then
CH := CH or $20
else
CH := CH and $DF;
AH := $01;
Intr($10,Regs);
end;
end;
begin
clrscr;
repeat
gettime(h,m,s,stot);
if (h<>h1) or (m<>m1) or (s<>s1) or (stot<>stot1) then begin
gotoxy(35,12);writeln('ÉÍÍÍÍÍÍÍÍÍÍÍ»');
gotoxy(35,13);writeln('º º');
gotoxy(35,14);writeln('ÈÍÍÍÍÍÍÍÍÍÍͼ');
gotoxy(36,13);
if h<10 then write('0');write(h,':');h1:=h;m1:=m;s1:=s;stot1:=stot;
if m<10 then write('0');write(m,':');
if s<10 then write('0');write(s,':');
if stot<10 then write('0');writeln(stot);
end;
kurzorzap(false);
until keypressed;
if (h>18) and (m>39) then write('Palo chod domov!!!');
delay(5000);
end.