You are on page 1of 5

10/9/21 8:17 Kahoot!

Fundamentals of Programming 1 (515-543)


Some questions about slides 515 to 543

2 favorites 9 plays 93 players

A public kahoot

Questions (8)

1 - Quiz
What type is not a standard type? 10 sec

bool

string

float

char

https://create.kahoot.it/details/76a3f512-b03e-480d-aeae-14d0f5ae327f 1/5
10/9/21 8:17 Kahoot!

2 - Quiz
Type declared by the programmer... 10 sec

Arrays

Enumerated

Structures

All of them

3 - Quiz
When using arrays... 20 sec

The compiler always checks that indexes are valid

= cannot be used to copy arrays

Elements are automatically initialized

Indexes can be of any known type

https://create.kahoot.it/details/76a3f512-b03e-480d-aeae-14d0f5ae327f 2/5
10/9/21 8:17 Kahoot!

4 - Quiz
C style strings... 10 sec

are arrays of characters

can be of different lengths

use '\0' as sentinel

All three are correct

5 - Quiz
What function do we use to get the length of a string? 10 sec

str. size()

str.lentgh()

length(str)

Any one of the other three

https://create.kahoot.it/details/76a3f512-b03e-480d-aeae-14d0f5ae327f 3/5
10/9/21 8:17 Kahoot!

6 - Quiz
Can variables of type string be compared with relational operators? 5 sec

Of course!

No, you must use library functions

7 - Quiz
Can C-style strings be compared with relational operators? 5 sec

Of course!

No, you must use library functions

https://create.kahoot.it/details/76a3f512-b03e-480d-aeae-14d0f5ae327f 4/5
10/9/21 8:17 Kahoot!

8 - Quiz
rfind() function (string library) is used... 20 sec

to find the first occurrence of a text in a string

to find the last occurrence of a text in a string

to find recursively a text in a string

to find a reversed text in a string

https://create.kahoot.it/details/76a3f512-b03e-480d-aeae-14d0f5ae327f 5/5

You might also like