T ni qiymati nechchiga teng int t=0, i=0
Download 254 Kb.
|
- Bu sahifa navigatsiya:
- Question text
t ni qiymati nechchiga teng int t=0, i=0; while (i<5) {
i+=2; t+=i; } 12
34 42 Dastur bo‘lagi bajarganingizdan keyin x o’zgaruvchisining qiymatini aniqlang: int x=1, y=0; while ( y < 12 ) y = 3 * ( ++x ) + 1; 5 4 7 2 1 for (i=1; i<=5; i++) sikl tanasi necha marta takrorlanadi? to‘g‘ri javob yo‘q 4 marta 5 marta
6 marta "while (ifoda_shart) {…}" konstruksiyadan foydalanish nimani bildiradi? Avval shartga tekshiriluvchi sikl Dastlab funktsiyani tekshiradigan sikl
Amal bajarilgandan so’ng shartga tekshiriluvchi sikl parametrik sikl C++ dasturlash tilida nechta takrorlanuvchi operatorlar bor? 2 4
3 Question 2Correct Mark 1.00 out of 1.00 Flag question Question textDastur bo‘lagi bajarganingizdan keyin x o’zgaruvchisining qiymatini aniqlang: int x=1, y=0; while ( y < 12 ) y = 3 * ( ++x ) + 1; 5 4
1 7
Question 3Incorrect Mark 0.00 out of 1.00 Flag question Question text
int s=0, i=1; while (i<5) { s+=i; i++; } 15 10
to‘g‘ri javob yo‘q Question 4Incorrect Mark 0.00 out of 1.00 Flag question Question texts ni qiymati nechchiga teng int s=0, i=1; do {
s+=i; i++; } while (i<5) to‘g‘ri javob yo‘q 10 16
15 Question 5Incorrect Mark 0.00 out of 1.00 Flag question Question textQuyidagi keltirilgan misollarning qaysi biri 1 dan 5 gacha bo‘lgan sonlarning yig‘indisini hisoblaydi? s=0;
for (i=1, i==5, i++) s=s+i;
s=0; for (i=1; i≤5; i++) s=s+i; s=0;
for (i>1; i<=5, i++) s=s+i;
s=0; for (i=1, i<=5; i++) s=s+i;
Question 6Correct Mark 1.00 out of 1.00 Flag question Question textint i=0; while (i<5) i++; sikl tanasi necha marta takrorlanadi? 5 marta
6 marta to‘g‘ri javob yo‘q 4 marta
Question 7Correct Mark 1.00 out of 1.00 Flag question Question textwhile (n>0) { s*=n; n-=2;} n=5 da dastur natijasini aniqlang
5 20 10 15 Question 8Correct Mark 1.00 out of 1.00 Flag question Question textSiklning tanasi necha marta bajarilishini aniqlang int i; for (i=0; i<7; i+=2) { ……. }
1 7 4 8 Question 9Incorrect Mark 0.00 out of 1.00 Flag question Question texts ni qiymati nechchiga teng int s=0, i=1; do {
i++; s+=i; } while (i<5); to‘g‘ri javob yo‘q 14 15 16 Question 10Incorrect Mark 0.00 out of 1.00 Flag question Question textt=0; bulganda while (i<5) { t+=i; i+=2;} va while (i<5) { i+=2; t+=i; } qaysi holatda t ning qiymati katta ?
while (i<5) { i+=2; t+=i; } holatda t qiymati katta while (i<5) { i+=2; t+=i; } holatda t qiymati kichkina while (i<5) { t+=i; i+=2;} holatda t qiymati katta ikki holatda ham natijalar bir hil Download 254 Kb. Do'stlaringiz bilan baham: |
ma'muriyatiga murojaat qiling