
Typ string C++
Authored by Mariia Shvydka
Computers
Professional Development
15 Questions
Used 3+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
1.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Celem poniższego (fragmentu) programu jest obliczyć liczbę liter a w słowie S:
int ile_a = 0;
for (int i = 0; i < S.length(); i++)
if (???)
ile_a++;
Co należy wstawić w miejsce znaków zapytania, aby program spełniał swoje założenia?
S == ’a’
S[i] = ’a’
i == ’a’
S[i] == ’a’
S == "a"
2.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Rozważmy fragment programu pokazany poniżej:
string generuj(int n) {
if (n == 0) return "a";
return string("b") + generuj(n - 1);
}
Jaki napis zwróci wywołanie generuj(3)?
bba
bbba
bbb
baaa
abbb
3.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Celem poniższego programu jest wypisać na wyjście kolejne litery alfabetu angielskiego (tzn. napis
abcdefghijklmnopqrstuvwxyz):
char znak = ’a’;
for (int i = 0; i < 26; i++)
cout << ???;
Co należy wstawić w miejsce znaków zapytania?
znak + i
'a'
znak + 'a'
znak + 'i'
znak
4.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Wczytanie słowa do zmiennej odbywa się dzięki:
sin<<
cin<<
writeln()
cout>>
5.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Wczytanie zdania do zmiennej odbywa się dzięki:
getline()
cin<<
writeln()
cout>>
6.
MULTIPLE SELECT QUESTION
30 sec • 2 pts
Linia kodu:
string PIN;
deklaruje zmienną PIN typu string
deklaruje typ PIN
deklaruje zmienną PIN
deklaruje ciąg znaków PIN
7.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
Biblioteka odpowiadająca za obsługę ciagów znaków w C++ to
iostream
stdlib
ctime
string
vector
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
10 questions
Python-Quiz-Basic-Datatypes
Quiz
•
12th Grade - Professi...
20 questions
SPARK FIDDLE
Quiz
•
Professional Development
20 questions
Basics of programming - Quiz - 01
Quiz
•
University - Professi...
10 questions
ER Model
Quiz
•
Professional Development
10 questions
C Programming
Quiz
•
Professional Development
10 questions
CHỦ ĐỀ: CẤU TRÚC RẼ NHÁNH
Quiz
•
Professional Development
10 questions
SQL
Quiz
•
Professional Development
10 questions
Moringa JavaScript Arrays
Quiz
•
5th Grade - Professio...
Popular Resources on Wayground
5 questions
This is not a...winter edition (Drawing game)
Quiz
•
1st - 5th Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
10 questions
Identify Iconic Christmas Movie Scenes
Interactive video
•
6th - 10th Grade
20 questions
Christmas Trivia
Quiz
•
6th - 8th Grade
18 questions
Kids Christmas Trivia
Quiz
•
KG - 5th Grade
11 questions
How well do you know your Christmas Characters?
Lesson
•
3rd Grade
14 questions
Christmas Trivia
Quiz
•
5th Grade
20 questions
How the Grinch Stole Christmas
Quiz
•
5th Grade
Discover more resources for Computers
26 questions
Christmas Movie Trivia
Lesson
•
8th Grade - Professio...
25 questions
Christmas Movies
Quiz
•
Professional Development
20 questions
Christmas Trivia
Quiz
•
Professional Development
15 questions
Fun Holiday Trivia
Quiz
•
Professional Development
25 questions
Name That Tune - Christmas
Quiz
•
Professional Development
29 questions
Christmas Song Emoji Pictionary
Quiz
•
Professional Development
9 questions
Holiday Movie Trivia
Lesson
•
Professional Development
34 questions
Winter Trivia
Quiz
•
Professional Development