CC113b Flashcards

1
Q

use the if condition if there is only
one condition.

A

If statement –

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

use this if there are two
conditions

A

if … else statement –

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

this may be used as an alternative
to if…else if…else

A

switch() … case

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

is used for executing a block of statements repeatedly
until a particular condition is satisfied.

A

loop

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

is an entry-controlled loop which first
checks the condition, then executes the code.

A

while

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

– is an exit-controlled loop which
first executes the code, then checks the
condition.

A

do while

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

– is an entry-controlled loop that includes
the initial value, test condition and
increment/decrement.

A

for

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

is a one of the data structure in C++,
that can store a fixed-size sequential collection
of elements of the same data type.

A

array

How well did you know this?
1
Not at all
2
3
4
5
Perfectly