Array Basics Assessment
Test your understanding of fundamental array concepts.
Full Name
*
First Name
Last Name
Which of the following best describes an array?
*
A collection of elements stored in a single variable, accessible by index.
A single value stored in multiple variables.
A type of function that returns random numbers.
Other
Select all valid ways to declare an array in your preferred programming language.
*
int[] numbers = new int[5];
var arr = [1, 2, 3];
array numbers = 1,2,3
let arr = Array(5);
Other
The first element in an array is at index [
Index of the first element
].
Given the array: arr = [10, 20, 30, 40], what is the value of arr[2]?
*
Briefly explain how you would add an element to the end of an array.
*
Rate your confidence in working with arrays.
1
2
3
4
5
Submit Assessment
Should be Empty: