Arrays and Strings MCQs

133 questionsC-ProgramPage 3 of 15

Practice free Arrays and Strings multiple-choice questions with instant answer feedback and step-by-step solutions. Click an option to check yourself, reveal the full explanation, and work through all 133 questions — no login required.

Question 19easy
Which function is used to copy one string to another in C?
Question 20medium
How do you access the last element of an array arr with n elements in C?
Question 21easy
What is the purpose of the fgets function in C?
Advertisement
Question 22easy
What does the strtok function do in C?
Question 23medium
How do you declare a two-dimensional integer array in C with 3 rows and 4 columns?
Question 24easy
What is the result of the expression strlen("Hello") in C?
Advertisement
Question 25easy
Which function is used to find the first occurrence of a character in a string in C?
Question 26medium
How do you declare a string in C that can store up to 50 characters?
Question 27easy
What is the purpose of the strncpy function in C?