{ (c) 1998 CREEQ <creeq@web.de> }
program Ball2;
uses Crt, Graph;
var
  Gd, Gm  : Integer;
  x, y    : Integer;
label 1,2,3,4;

begin
  x := 649;
  y := 489;
  Gd := Detect;
  InitGraph(Gd, Gm, '');
  if GraphResult <> grOk then
    Halt(1);
  setcolor(white);
  circle(x,y,10);
1:repeat
  setcolor(black);
  circle(x,y,10);
  dec(x);
  dec(y);
  setcolor(white);
  circle(x,y,10);
  circle(x,y,9);
  circle(x,y,8);
  circle(x,y,7);
  circle(x,y,6);
  circle(x,y,5);
  circle(x,y,4);
  circle(x,y,3);
  circle(x,y,2);
  circle(x,y,1);
  if keypressed then halt;
  if y = 10 then goto 2;
  if x = 10 then goto 4;
  until false;
2:repeat
  setcolor(black);
  circle(x,y,10);
  dec(x);
  inc(y);
  setcolor(white);
  circle(x,y,10);
  circle(x,y,9);
  circle(x,y,8);
  circle(x,y,7);
  circle(x,y,6);
  circle(x,y,5);
  circle(x,y,4);
  circle(x,y,3);
  circle(x,y,2);
  circle(x,y,1);
  if keypressed then halt;
  if y = 469 then goto 1;
  if x = 10 then goto 3;
  until false;
3:repeat
  setcolor(black);
  circle(x,y,10);
  inc(x);
  inc(y);
  setcolor(white);
  circle(x,y,10);
  circle(x,y,9);
  circle(x,y,8);
  circle(x,y,7);
  circle(x,y,6);
  circle(x,y,5);
  circle(x,y,4);
  circle(x,y,3);
  circle(x,y,2);
  circle(x,y,1);
  if keypressed then halt;
  if y = 469 then goto 4;
  if x = 629 then goto 2;
  until false;
4:repeat
  setcolor(black);
  circle(x,y,10);
  inc(x);
  dec(y);
  setcolor(white);
  circle(x,y,10);
  circle(x,y,9);
  circle(x,y,8);
  circle(x,y,7);
  circle(x,y,6);
  circle(x,y,5);
  circle(x,y,4);
  circle(x,y,3);
  circle(x,y,2);
  circle(x,y,1);
  if keypressed then halt;
  if y = 10 then goto 3;
  if x = 629 then goto 1;
  until false;
  CloseGraph;
end.


