1-Program je
2-Program tiež
3,Nakresli Trojuholnik,Stvorec,Obdlžnik.
4.Zahra Melodiu
clrscrrô;
Aby v poslednej casti programu nakreslilo Trojuholnik Okraje Modre,
Stvorec, okraje Zelene, Obdlžnik, okraje Cerverne
A bude hrat melodiu
delay (5000)
end.
Do vecera to potrebujem zajtra to musim odovzdat
Kód: Vybrať všetko
program text;
uses crt;
var cisla:array[1..10] of integer;
a,b,c,d:integer;
begin
ClrScr;
gotoxy(37,5);
textcolor(15);
write ('Skola');
gotoxy(26,6);
textcolor(14);
write ('Stredne Odborne Uciliste Nizna');
gotoxy(36,10);
textcolor(15);
write ('Trieda');
gotoxy(38,11);
textcolor(14);
write('2.C');
gotoxy(34,14);
textcolor(15);
write('Nazov Ulohy');
gotoxy(28,15);
textcolor(14);
write('Generovanie Nahodych Cisiel');
gotoxy(36,18);
textcolor(15);
write('Riesil');
gotoxy(34,19);
textcolor(14);
write('Lukas Jaros');
gotoxy(37,21);
textcolor(15);
write('Datum');
gotoxy(35,22);
textcolor(14);
write('15.6.2007');
gotoxy(45,26);
textcolor(2);
write('(Pokracujte Stlacenim Klavesy)');
readkey;
clrscr;
randomize;
for a:=1 to 10 do
begin
cisla[a]:=10+random(31);
if cisla[a]=18 then inc(cisla[a]);
end;
for a:=1 to 10 do
for b:=1 to a-1 do while(cisla[a]=cisla[b]) do cisla[a]:=20+random(20);
gotoxy(34,5);
writeln('Neusporiadane');
gotoxy(25,8);
for a:=1 to 10 do write(' ',cisla[a]);
gotoxy(35,20);
writeln('Usporiadane');
gotoxy(25,22);
for a:=2 to 10 do
begin
b:=1;
while(cisla[a]>cisla[b]) do inc(b);
c:=cisla[a];
for d:=a downto b+1 do cisla[d]:=cisla[d-1];
cisla[b]:=c;
end;
for a:=1 to 10 do write(' ',cisla[a]);
gotoxy(45,26);
textcolor(2);
write('(Spustenie Dalsieho Programu za 5s)');
delay (5000);
end.