Instructiuni Repetitive C++

Quiz
•
Computers
•
10th Grade
•
Medium
CARMEN ANTON
Used 16+ times
FREE Resource
9 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
45 sec • 1 pt
Ce este o instructiune for in C++?
Este o instructiune utilizata pentru operatii de I/O
O instructiune for în C++ este o structură de control care permite execuția repetată a unui bloc de cod pentru un anumit număr de ori.
O instructiune for in C++ este o instructiune care verifica o conditie si executa o instructiune in functie de rezultatul acesteia.
O instructiune for in C++ este utilizata pentru a defini o functie.
2.
MULTIPLE SELECT QUESTION
30 sec • 1 pt
Care este sintaxa unui for in C++?
for(initializare; conditie; incrementare:) // codul pe care dorim sa il repetam
for(initializare; conditie; incrementare): { // codul pe care dorim sa il repetam }
for(initializare; conditie; incrementare) { // codul pe care dorim sa il repetam }
for(initializare; conditie; decrementare;) { // codul pe care dorim sa il repetam }
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Cum se pot afisa numerele naturale pare din intervalul [2, 100] in C++?
for(int i = 2; i < 100; i++) { cout<<i<<" "; }
for(int i = 1; i <= 100; i=i+2) { cout<<i<<" "; }
for(int i = 2; i <= 100; i=i+2) { cout<<i<<" "; }
for(int i = 2; i <= 100; i++) { cout<<i<<" "; }
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Ce este un do-while in C++?
Un do-while in C++ nu poate contine instructiuni alternative de tip if.
Un do-while in C++ nu poate fi folosit pentru a parcurge un interval de numere naturale.
Un do-while in C++ este un tip special de functie.
Un do-while in C++ este similar cu un while, cu diferenta ca instructiunile din interiorul sau sunt executate macar o data.
5.
MULTIPLE SELECT QUESTION
30 sec • 1 pt
Care este sintaxa unui do-while in C++?
do { instructiuni; } do while (condition);
do (condition) { instructiuni;} while;
do { instructiuni; } while (condition);
do { instructiuni; } while;
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Cum functioneaza un do-while in C++?
Un do-while in C++ se executa invers fata de un while.
Un do-while in C++ se executa de mai multe ori pana cand conditia este indeplinita.
Un do-while in C++ se executa cel putin o data, deoarece conditia este verificata dupa executarea blocului de cod.
Un do-while in C++ se executa doar daca conditia este adevarata.
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Care sunt avantajele folosirii unui do-while in comparatie cu un while?
Un do-while nu permite specificarea unei condiții de oprire.
Un do-while poate fi mai ineficient decât un while.
Un do-while nu poate fi folosit pentru a citi mai multe date.
Un do-while garantează că instrucțiunile din interiorul buclei sunt executate cel puțin o dată.
8.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Poti folosi un do-while loop pentru a itera peste un array in C++?
Nu
Da, dar numai in Python
Da
Da, dar numai in Java
9.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Care este diferenta de functionare intre un for loop si un do-while loop in C++?
For loop checks the condition after each iteration, while do-while loop checks the condition before each iteration.
For loop and do-while loop have the same functionality in C++.
For loop and do-while loop are not supported in C++.
For loop checks the condition before each iteration, while do-while loop checks the condition after each iteration.
Similar Resources on Wayground
10 questions
Edhesive Python Unit 4: Test Review

Quiz
•
10th - 11th Grade
12 questions
CodeHS Unit 1

Quiz
•
9th - 12th Grade
11 questions
while and do while Loop

Quiz
•
10th Grade
10 questions
Python Condition Controlled Iteration

Quiz
•
10th Grade
10 questions
REVIEW QUIZ FOR & WHILE LOOP

Quiz
•
10th Grade
14 questions
1.1.5 CSE Iteration and Loops

Quiz
•
9th - 12th Grade
10 questions
Programming

Quiz
•
1st - 10th Grade
13 questions
KS4 Python While Loops and For Loops

Quiz
•
9th - 11th Grade
Popular Resources on Wayground
18 questions
Writing Launch Day 1

Lesson
•
3rd Grade
11 questions
Hallway & Bathroom Expectations

Quiz
•
6th - 8th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
40 questions
Algebra Review Topics

Quiz
•
9th - 12th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
19 questions
Handbook Overview

Lesson
•
9th - 12th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
Discover more resources for Computers
40 questions
Algebra Review Topics

Quiz
•
9th - 12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
19 questions
Handbook Overview

Lesson
•
9th - 12th Grade
10 questions
Characteristics of Life

Quiz
•
9th - 10th Grade
10 questions
Essential Lab Safety Practices

Interactive video
•
6th - 10th Grade
62 questions
Spanish Speaking Countries, Capitals, and Locations

Quiz
•
9th - 12th Grade
20 questions
First Day of School

Quiz
•
6th - 12th Grade
21 questions
Arithmetic Sequences

Quiz
•
9th - 12th Grade