esercizi di fisicacon turbo pascal 1.1 su mac

(* conca1.fis immagini specchi concavi *)
program concavi;
var dsorgente,dimmagine,altezzai:real;
    altezzas,fuoco:integer;
    contatore:integer;
begin
  clearscreen;
 fuoco:=40;
 dsorgente:=120;
 altezzas:=50;
 for contatore:=1 to 11 do
  begin
  if dsorgente=fuoco then
  begin
  dsorgente:=dsorgente-10;
  writeln('sorgente su fuoco=immagine a infinito');
  end;
  dimmagine:=fuoco*dsorgente/(dsorgente-fuoco);
  altezzai:= dimmagine*altezzas/dsorgente;
  write('dsorgente=',dsorgente:3:0,'...dimmagine=',dimmagine:3:0);
  writeln('...altezzas=',altezzas,'...altezzai=',altezzai:3:0);
  dsorgente:=dsorgente-10;
  end;
  writeln('premi enter per finire');
  readln;
end.