- program dictionnaire;
-
- {$APPTYPE CONSOLE}
-
- uses
- SysUtils,
- crt;
-
- const nb_max_mot = 369084;
- last_jour ='25/01/2005';
- type fichier = file of char;
- type T_tab_mot = array[0..nb_max_mot] of string[16];
- var objet : fichier;
- car,reponse :char;
- mot,le_mot : string[16];
- i,j : integer;
- les_mots : T_tab_mot;
- resultat : boolean;
- t_debut,t_fin : Tdatetime;
- label ici,labas;
-
-
- begin
-
-
- textcolor(9);write('KHARAL dafkoy charger .....');
- mot:='';
- j:=0;
- assign(objet,'tous_les_mots.jul');
- reset(objet);
- t_debut := time;
- i:=0;
- seek(objet,i);
- read(objet,car);
- //while not(eof(objet)) do begin
- repeat
- if car=#13 then begin
- les_mots[j]:=mot;
- delete(les_mots[j],length(les_mots[j]),1);
- mot:='';
- inc(j);
- i:=i+1;
- end{if};
- seek(objet,i);
- read(objet,car);
- mot:=mot + car;
- i:=i+1;
- until j=nb_max_mot;
- //end {while};
- close(objet);
-
- t_fin := time;
- ici:CLRSCR;
- textcolor(15);writeln('Parena en ',timetostr(t_fin-t_debut),' secondes');
- writeln;
- textcolor(15);write('DEFAL MOT BI NGAY SET ? : ');
- readln(le_mot);
- le_mot := le_mot;
- resultat := false;
- writeln;
- for i :=0 to j do begin
-
- if le_mot = les_mots[i]then begin
- textcolor(14);write(' WAW ');
- textcolor(7);write(les_mots[i]);
- textcolor(14);writeln(' AMNA !');
- writeln;
- resultat:= true;
- end{if};
-
- END{for};
- if NOT (resultat) then begin
- textcolor(12);write(' ----->>>> DEDET ');
- textcolor(7);write(le_mot);
- textcolor(12);writeln(' AMOUL TEGUILL GAW <<<<----- !');
- writeln;
- end{if};
-
-
- textcolor(15);writeln('DA NGAY SETAT BENEENE MOT ? [O/N] ?');
- reponse:=readkey;
- case upcase(reponse) of
- 'O' : goto ici;
- 'N' : exit;
- else goto ICI;
- end{case};
-
-
- end.
program dictionnaire;
{$APPTYPE CONSOLE}
uses
SysUtils,
crt;
const nb_max_mot = 369084;
last_jour ='25/01/2005';
type fichier = file of char;
type T_tab_mot = array[0..nb_max_mot] of string[16];
var objet : fichier;
car,reponse :char;
mot,le_mot : string[16];
i,j : integer;
les_mots : T_tab_mot;
resultat : boolean;
t_debut,t_fin : Tdatetime;
label ici,labas;
begin
textcolor(9);write('KHARAL dafkoy charger .....');
mot:='';
j:=0;
assign(objet,'tous_les_mots.jul');
reset(objet);
t_debut := time;
i:=0;
seek(objet,i);
read(objet,car);
//while not(eof(objet)) do begin
repeat
if car=#13 then begin
les_mots[j]:=mot;
delete(les_mots[j],length(les_mots[j]),1);
mot:='';
inc(j);
i:=i+1;
end{if};
seek(objet,i);
read(objet,car);
mot:=mot + car;
i:=i+1;
until j=nb_max_mot;
//end {while};
close(objet);
t_fin := time;
ici:CLRSCR;
textcolor(15);writeln('Parena en ',timetostr(t_fin-t_debut),' secondes');
writeln;
textcolor(15);write('DEFAL MOT BI NGAY SET ? : ');
readln(le_mot);
le_mot := le_mot;
resultat := false;
writeln;
for i :=0 to j do begin
if le_mot = les_mots[i]then begin
textcolor(14);write(' WAW ');
textcolor(7);write(les_mots[i]);
textcolor(14);writeln(' AMNA !');
writeln;
resultat:= true;
end{if};
END{for};
if NOT (resultat) then begin
textcolor(12);write(' ----->>>> DEDET ');
textcolor(7);write(le_mot);
textcolor(12);writeln(' AMOUL TEGUILL GAW <<<<----- !');
writeln;
end{if};
textcolor(15);writeln('DA NGAY SETAT BENEENE MOT ? [O/N] ?');
reponse:=readkey;
case upcase(reponse) of
'O' : goto ici;
'N' : exit;
else goto ICI;
end{case};
end.