Program Hedefi_bul;
Uses crt;
Label
tekrar_gir;
var
x,y:byte;
satir,sutun:byte;
a,ts:byte;
begin
{ekranda rastgele bir kordinat seçiliyor...}
randomize;
x:=random(78)+2;
y:=random(19)+2;
{..rastgele korditanlar Seçildi}
ts:=0; {Tahmin Sayisi}
tekrar_gir:
clrscr;
{Çerçeve çizlmeye basliyor...}
for a:=1 to 80 do begin
gotoxy(a,1);write('.');
gotoxy(a,21);write('.');
end;
for a:=1 to 21 do begin
gotoxy(1,a);write('.');
gotoxy(80,a);write('.');
end;
{...Çerçeve çizildi}
gotoxy(1,23);write('Tahmininizi Giriniz->');
gotoxy(30,23);write('Sutun No...:');
gotoxy(50,23);write('Satir No...:');
gotoxy(x,y);write('*');
gotoxy(43,23);readln(sutun);
gotoxy(63,23);readln(satir);
if (not (satir in [2..20])) or (not (sutun in [2..79])) then goto tekrar_gir;
ts:=ts+1; {Tahmin sayisi artiriliyor}
if (satir=y) and (sutun=x) then begin
gotoxy(30,12);write('Aferin Bildiniz!');
gotoxy(30,13);write('Tahmin Sayisi: ',ts);
end else begin
gotoxy(sutun,satir);write('X');
delay(1000);
gotoxy(sutun,satir);write(' ');
goto tekrar_gir;
end;
readln;
end.
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX XXXXXXXXXXXXXXXXXXXXXXXX
uses crt;
var
b,t:char;
a,i,c,x,w,y,d:integer;
procedure cerceve(x1,y1,x2,y2:integer);
begin
gotoxy(x1,y1);write(chr(218));
gotoxy(x2,y1);write(chr(191));
gotoxy(x1,y2);write(chr(192));
gotoxy(x2,y2);write(chr(217));
for i:=x1+1 to x2-1 do
begin
gotoxy(i,y1);write(chr(196));
gotoxy(i,y2);write(chr(196));
end;
for i:=y1+1 to y2-1 do
begin
gotoxy(x1,i);write(chr(179));
gotoxy(x2,i);write(chr(179));
end;end;
begin
clrscr;
textcolor(9);
textbackground(4);
clrscr;
a:=20;
y:=1;
c:=60;
d:=1;
w:=100;
for x:=1 to 40 do
begin
gotoxy(c,d);write('YAZILIM');
gotoxy(a,y);write('TREX');
w:=w+50;
a:=a+1;
y:=y+1;
c:=c-1;
d:=d+1;
sound(w);
delay(100);
nosound;
end;
gotoxy(c,d);writeln('devam etmek i‡in bir tusa bas�n');
t:=readkey;
clrscr;
a:=200;
repeat
textbackground(4);
clrscr;
textcolor(15);
cerceve(7,7,75,14);
gotoxy(25,10);writeln('TREX YAZILIM, PROGRAMLAR šRETIR');
cerceve(25,20,50,30);
gotoxy(29,24);writeln('>>>> ORK X550 q< harfine bas�n');
textcolor(15);
gotoxy(26,28);write('do');
gotoxy(26,29);write('ÛÛ');
gotoxy(29,28);write('re ');
gotoxy(29,29);write('ÛÛ');
gotoxy(32,28);write('mi');
gotoxy(32,29);write('ÛÛ');
gotoxy(35,28);write('fa');
gotoxy(35,29);write('ÛÛ');
gotoxy(38,28);write('so');
gotoxy(38,29);write('ÛÛ');
gotoxy(41,28);write('la');
gotoxy(41,29);write('ÛÛ');
gotoxy(44,28);write('si');
gotoxy(44,29);write('ÛÛ');
gotoxy(47,28);write('do');
gotoxy(47,29);write('ÛÛ');
b:=readkey;
if b='a' then
begin
sound(500);
textcolor(16);gotoxy(26,29);write('ÛÛ');
delay(a);
nosound;
end;
if b='s' then
begin
sound(600);
textcolor(16);gotoxy(29,29);write('ÛÛ');
delay(a);
nosound;
end;
if b='d' then
begin
sound(700);
textcolor(16);gotoxy(32,29);write('ÛÛ');
delay(a);
nosound;
end;
if b='f' then
begin
sound(800);
textcolor(16);gotoxy(35,29);write('ÛÛ');
delay(a);
nosound;
end;
if b='g' then
begin
sound(900);
textcolor(16);gotoxy(38,29);write('ÛÛ');
delay(a);
nosound;
end;
if b='h' then
begin
sound(1000);
textcolor(16);gotoxy(41,29);write('ÛÛ');
delay(a);
nosound;
end;
if b='j' then
begin
sound(1100);
textcolor(16);gotoxy(44,29);write('ÛÛ');
delay(a);
nosound;
end;
if b='k' then
begin
sound(1200);
textcolor(16);gotoxy(47,29);write('ÛÛ');
delay(a);
nosound;
end;
until b='q'
end.