Which of the following data structure can’t store non-homogeneous data elements? A) Arrays B) Linked Lists C) Trees D) Stacks Explain
Which of the following is non-liner data structure?
A) Arrays
B) Linked Lists
C) Strings
D) Trees
Explain
1) Answer: (A)Arrays: Array is a user defined data structure which is used to indicate multiple variable and store the multiple homogenous value in continous memory locations.Non homogeous data refers to set of non- similar data type where as array consists of set of similar data such as set of integers or set of chars etc. Non -homogenous data consists of a set consisting ofboth chars and integers.Hence the answer to the above question is Arrays
2)Answer: (D) Trees: Tree is a non-linear data structure because it is connected to several other data items.So a tree data has the possibility to reach one-or-more data items which implies that if you'' draw the structure of tree on a paper it will never come on a single line. Hence it's a non-linear data structure.
Get Answers For Free
Most questions answered within 1 hours.