O`zbеkiston rеspublikasi oliy va o`rta maxsus ta'lim



Download 1,59 Mb.
bet67/75
Sana26.02.2022
Hajmi1,59 Mb.
#465842
1   ...   63   64   65   66   67   68   69   70   ...   75
Bog'liq
Dasturlash

18) program res; uses CRT;
const N=5;
var A : array [ 1..N, 1..N ] of integer = ((1, 1, 1, 1, 1), (1, 2, 3, 4, 5), (1, 2, 3, 4, 5),(2, 2, 2, 2, 2),(1, 3, 3, 7, 5)); var i, j, str, sum, max : integer; b: boolean; BEGIN
ClrScr; max:= -1; str:= -1; for i:= 1 to N do begin sum:= 0; b:= false; for j:= 1 to N do begin sum:= sum + abs(A[i,j]); if not odd (A[i,j]) then b:= true; end; if (not b) and (sum>max) then begin max:= sum; str:= i; end; end; WriteLn('< OK >'); ReadKey; END.
19) program N1;
var N:integer;
function KOL(N:integer):integer;
begin if N>9 then KOL:=KOL(N mod 10)+KOL(N div 10) else KOL:=1;
end;BEGIN ReadLn(N); WriteLn(KOL(N)); ReadLn; END.
20) program pasc;
var b,a,n,k: integer;
begin readln(n); k:=n; a:=k mod 10; repeat b:=k mod 10; k:=k div 10 until k div 10 =0; b:=k mod 10; writeln(a,n div 10 div 10 mod 10,n div 10 mod 10,b) end.
21) PROGRAM pasc;
TYPE massiv=array [1..50] of integer;
var a:massiv; n,i:integer; begin readln(n);
i:=1; while n>=2 do begin a[i]:= n mod 2; i:=i+1;
n:= n div 2; end; i:=i-1; write(n); while I < >0 do
begin write(' ',a[i]); i:=i-1; end; writeln end.
22) program 3;
uses crt;
var i , s, n, dni, a : Integer; begin ClrScr;
ReadLn(n); ReadLn(dni); s := 0; a := 0; if dni > n then begin
TextColor(Red); GotoXY(15,5); GotoXY(15,6); end else begin for i := 1 to dni do begin if a mod n = 0 then begin
s := n div 2; n := n - s; end else begin
a := n - 1; s := a div 2; n := n - s + 1 end end;
end; WriteLn; Write('Press Enter'); ReadLn end.
23) program 4;
uses crt;
var vklad, prozent, a : Real; i, let, b : Integer; begin
ClrScr; ReadLn(vklad); ReadLn(let); ReadLn(prozent);
for i := 1 to let do begin a := (vklad / 100) * prozent;
vklad := vklad + a end; WriteLn( vklad:10:2); WriteLn;
WriteLn('Press Enter'); ReadLn end.
24) program 7;
uses crt;
var i, a, b, n : Integer; begin ClrScr; ReadLn(n);
a := 0; i := 0; b := 0; repeat a := a + 2; Inc(i);
b := a * (a + 2) until b >= n; WriteLn( i, i + 1); WriteLn;
Write('Press Enter'); ReadLnend.

Download 1,59 Mb.

Do'stlaringiz bilan baham:
1   ...   63   64   65   66   67   68   69   70   ...   75




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2024
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish