
C Strings Quiz

Quiz
•
Computers
•
12th Grade
•
Medium
Manoj R
Used 3+ times
FREE Resource
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct way to declare a string in C?
char str = 'Hello';
char str[] = "Hello";
string str = 'Hello';
int str = 'Hello';
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which function is used to output a string in C?
print()
display()
printf()
printline()
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which function is used to compare two strings in C?
compareStr()
strcomp()
strcmp()
stringCompare()
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
How can you concatenate two strings in C?
concat(string1, string2)
strcat(string1, string2)
strconcat(string1, string2)
strjoin(string1, string2)
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the significance of the strcmp() function in C?
It is used to concatenate two strings in C.
It is used to find the length of a string in C.
It is used to convert a string to uppercase in C.
It is used to compare two strings in C.
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Describe the role of strcat() function in C string manipulation.
The role of strcat() function in C string manipulation is to concatenate two strings.
The role of strcat() function is to split strings.
strcat() function reverses the order of strings.
strcat() function compares two strings.
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the return type of strlen() function in C?
int
char
size_t
void
Create a free account and access millions of resources
Similar Resources on Wayground
12 questions
Java Strings

Quiz
•
9th - 12th Grade
11 questions
45. Programming 1 : Data Types and Casting

Quiz
•
9th - 12th Grade
15 questions
Chapter 3 Review

Quiz
•
9th - 12th Grade
15 questions
Python Fundamentals

Quiz
•
11th - 12th Grade
8 questions
Topics 7 & 8 - Static Methods/Variables and Null Keyword

Quiz
•
12th Grade
15 questions
Problem Solving using Python and R - UNIT I STRINGS MCQS

Quiz
•
12th Grade
10 questions
Python Variables

Quiz
•
7th - 12th Grade
9 questions
C# Variables and Data Types

Quiz
•
8th Grade - University
Popular Resources on Wayground
10 questions
Video Games

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

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

Quiz
•
5th Grade
10 questions
UPDATED FOREST Kindness 9-22

Lesson
•
9th - 12th Grade
22 questions
Adding Integers

Quiz
•
6th Grade
15 questions
Subtracting Integers

Quiz
•
7th Grade
20 questions
US Constitution Quiz

Quiz
•
11th Grade
10 questions
Exploring Digital Citizenship Essentials

Interactive video
•
6th - 10th Grade