Array Accenture Quiz
Array Accenture Quiz
Quiz review
Started on Saturday, 18 May 2024, 9:33 PM
State Finished
Completed on Saturday, 18 May 2024, 9:44 PM
Time taken 11 mins 46 secs
Marks 17.50/20.00
Grade 87.50 out of 100.00
Feedback Congratulations! You have scored more than 80%.
Question 1
Correct
53051
A mathematical quiz context happened in a school and the scores are stored in an array named quizmark. The coordinating person
wants to copy the quiz score into another array named copyquizmark. Which of these options will do that?
Select one:
a. copyquizmark[n] <- quizmark[n]
b.
FOR index <- 0 to n
END FOR
53051
c.
copyquizmark <- quizmark
d.
We cannot copy the values from one array to another.
53051
Using for loop helps to copy the elements from one array to another array
The correct answer is:
FOR index <- 0 to n
copyquizmark[index] <- quizmark[index]
index <- index+1
END FOR
Question 2
Correct
Assume,
Select one:
a. 100
b. 99
c.
Infinite number of elements
d.
The statement gives no clue about the number of elements that can be stored
53051
Your answer is correct.
From the given statement, it is predictable that number 99 is assigned to 101 th position of the array. But, there is no clue about the total
size of the array and the number of elements that can be stored
The correct answer is:
The statement gives no clue about the number of elements that can be stored
Question 3
Correct
53051
Mark 1.00 out of 1.00
Question 4
Correct
Which of the following are False with respect to the manipulation of arrays?
c.
An array can store homogeneous data.
d.
An array can store heterogeneous data
Question 5
Correct
53051
Mark 1.00 out of 1.00
Select one:
True
False
53051
Size of the array cannot be negative. But the elements stored inside an array can be negative
The correct answer is 'True'.
Question 6
Partially correct
The names of all associates undergoing training are stored in an array named associate_name[50]. The 5th associates’ name is
retrieved as
b.
associate_name[4]
c.
associate_name[3+1]
d. associate_name[6]
53051
Your answer is partially correct.
since array index starts from 0, the fifth element is accessed is accessed by array[4]. It is possible to perform arithmetic operation in an
array position
You have correctly selected 1.
The correct answers are:
associate_name[4],
associate_name[3+1]
Question 7
Incorrect
53051
Mark 0.00 out of 1.00
Select one:
a.
the name of the array
b.
53051
the data type of the array
d.
the index of the array
It is not mandatory to specify the elements to be stored in the array when declaring an array
The correct answer is: the elements to be stored in the array
Question 8
Correct
It is not possible to do a search operation in an array that is not sorted. State True/False.
Select one:
True
False
It is not mandatory to sort an array when searching an element randomly. It can be either sorted or unsorted
The correct answer is 'False'.
Question 9
Correct
53051
The operation of ordering the elements in the list is known as [Sorting].
Question 10
Correct
Select one:
True
53051
False
Question 11
Correct
Question 12
Correct
53051
Assume you have an array named numbers of size 10.
b.
numbers[9] <- 5
c. numbers[10] <- 11
array index starts from 0 to 9, for 10 elements. Assigning values to numbers[10],numbers[11] is not valid, since the index exceeds the
size of array resulting in unpredictable results
The correct answers are: numbers[0] <- 10, numbers[9] <- 5
53051
Question 13
Correct
Select one:
a.
Elements in an array are arranged in ascending order by default
b.
Elements in an array are arranged in descending order by default
53051
Elements in an array are arranged in a contiguous manner and are of fixed size
The correct answer is: Elements in an array are arranged contiguously.
Question 14
Correct
Question 15
Incorrect
53051
Consider you buy a laptop. You want to store the details of that laptop such as price,
Select one:
a. Yes
b. No
No, It is not possible. An array can store data of same type. since model_name consists of letters, model_no consists of number etc, it is
not possible to the details into a single array
The correct answer is: No
Question 16
Correct
List of songs stored in your mobile phone is a good example for single-dimensional arrays
Question 17
Correct
53051
Consider you want to compare the prices of redmi , sony, samsung phones in three online sites like amazon,flipkart,ebay.
Select one:
a.
three-dimensional arrays
b.
one-dimensional array
c. two-dimensional arrays
53051
Your answer is correct.
To compare 3 mobile phones in 3 different online sites, 2-d arrays can be used.
53051
Question 18
Correct
It is possible to traverse through an array from the first position to the last and not vice versa. State true or false.
Select one:
True
False
Question 19
Correct
Select one:
a. Three dimensional array
b. Two-dimensional array
c.
one-dimensional array
53051
Your answer is correct.
53051
Question 20
Correct
Choose the correct Pseudo code to store names in an array and display a name.
a.
BEGIN
INPUT name
PRINT name
END
b.
BEGIN
INPUT name
PRINT name
END
53051
c.
BEGIN
INPUT name
DECLARE name [20]
PRINT name
END
d.
BEGIN 53051
INPUT name
END
PRINT name
INPUT name
PRINT name
END
Jump to...
Pre-Quiz ►
53051
53051
53051