When an array sales [5)[12] is declared without specifying initial values, what is the initial value of sales[0][0] ?(a) 0
(b) default value
(c) compilation error
(d) 60
Answers
Answered by
11
When an array named sales of dimensions [5][12] is declared, without specifying any values, the initial value of sales[0][0] index is (b) Default value.
This default value is often called a garbage value, since this output of the index has no meaning, and has simply been entered by the computer to indicate that the array memory space is filled. When any variable or data structure such as array is declared, but not initialised, then garbage values are randomly generated and filled in the memory blocks of that respective index.
Similar questions
Social Sciences,
5 months ago
Chemistry,
5 months ago
Physics,
11 months ago
Biology,
11 months ago
Science,
1 year ago