Strings

Quiz
•
Computers
•
University
•
Hard

Pavol Zajac
Used 6+ times
FREE Resource
6 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is returned from strlen("test\n");
4
5
6
7
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Given char buffer[81], which statement correctly reads a single line into buffer?
gets(buffer);
fgets(buffer, 81, stdin);
scanf("%s", buffer);
scanf("%80s", buffer);
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Given char buffer[81], which statement correctly reads a single word into buffer?
gets(buffer);
fgets(buffer, 81, stdin);
scanf("%s", buffer);
scanf("%80s", buffer);
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which expression is true, if pointer test points to string with content "test"?
test == "test"
strcmp(test, "test") == 0
strcmp(test, "test")
strstr(test, "test") == 0
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
We have char str[81] = "test". How do we concatenate it with "string"?
strcat(str, "string");
strcpy(str, "string");
str += "string";
str = "teststring";
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Let
char *test = "teststring";
char *ptr = strstr(test, "str");
What is the value of ptr - test?
Undefined.
0
4
5
Similar Resources on Wayground
10 questions
QUIZ 2

Quiz
•
University
8 questions
C++ Strings Quiz

Quiz
•
University
7 questions
PA2 - 1 - Přetěžování, reference, const

Quiz
•
University
10 questions
c basic

Quiz
•
University
9 questions
Introducción a Python

Quiz
•
University
10 questions
Web Development Workshop

Quiz
•
University - Professi...
7 questions
Taller de Programación en Python

Quiz
•
University
6 questions
Python Basics

Quiz
•
University
Popular Resources on Wayground
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
10 questions
9/11 Experience and Reflections

Interactive video
•
10th - 12th Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
9 questions
Tips & Tricks

Lesson
•
6th - 8th Grade
Discover more resources for Computers
21 questions
Spanish-Speaking Countries

Quiz
•
6th Grade - University
20 questions
Levels of Measurements

Quiz
•
11th Grade - University
7 questions
Common and Proper Nouns

Interactive video
•
4th Grade - University
12 questions
Los numeros en español.

Lesson
•
6th Grade - University
7 questions
PC: Unit 1 Quiz Review

Quiz
•
11th Grade - University
7 questions
Supporting the Main Idea –Informational

Interactive video
•
4th Grade - University
12 questions
Hurricane or Tornado

Quiz
•
3rd Grade - University
7 questions
Enzymes (Updated)

Interactive video
•
11th Grade - University