C Language Array Quiz

Quiz
•
Computers
•
University
•
Medium
Fidel Romasanta
Used 7+ times
FREE Resource
19 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
What is right way to Initialize array?
int num[6] = { 2, 4, 12, 5, 45, 5 };
int n{} = { 2, 4, 12, 5, 45, 5 };
int n{6} = { 2, 4, 12 };
int n(6) = { 2, 4, 12, 5, 45, 5 };
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
An array elements are always stored in ________ memory locations.
sequential
Random
Sequential and Random
None of the above
3.
MULTIPLE CHOICE QUESTION
45 sec • 2 pts
What is the result of the code below?
int a[]={11,13,56,20,5};
printf("%d",a[2]);
garbage value
13
56
20
4.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
How to accesses the seventh element in array "myArr" with 100 elements?
myArr[6]
myArr[7]
myArr{6}
myArr{7}
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
An array Index starts with _____.
-1
0
1
2
6.
MULTIPLE CHOICE QUESTION
30 sec • 2 pts
What is the minimum and maximum Indexes of array "int myArr[9];"
-1, 8
0, 8
1,9
None of the above
7.
MULTIPLE CHOICE QUESTION
45 sec • 2 pts
What is the output of this code fragment?
int a[2][3] = { {1,1,1},{2,2,2}};
printf("%d", a[1][1]);
1
Error
2
0
Create a free account and access millions of resources
Similar Resources on Wayground
20 questions
РЭУ тест по Python

Quiz
•
University
15 questions
BASIC C PROGRAMMING QUIZ

Quiz
•
University
15 questions
DATA STRUCTURES QUIZ

Quiz
•
University
20 questions
C Programming Quiz(session 1)

Quiz
•
University
16 questions
Lógica de Programação

Quiz
•
University
15 questions
Quiz of Array

Quiz
•
University
20 questions
C Programming Assessment-1

Quiz
•
University
20 questions
Quiz 1_DSA

Quiz
•
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
Discover more resources for Computers
10 questions
Would you rather...

Quiz
•
KG - University
20 questions
Definite and Indefinite Articles in Spanish (Avancemos)

Quiz
•
8th Grade - University
7 questions
Force and Motion

Interactive video
•
4th Grade - University
10 questions
The Constitution, the Articles, and Federalism Crash Course US History

Interactive video
•
11th Grade - University
7 questions
Figurative Language: Idioms, Similes, and Metaphors

Interactive video
•
4th Grade - University
20 questions
Levels of Measurements

Quiz
•
11th Grade - University
16 questions
Water Modeling Activity

Lesson
•
11th Grade - University
10 questions
ACT English prep

Quiz
•
9th Grade - University