State the advantages and limitations of using structure over array
Answers
Answered by
12
Advantages of structure over Array
- Main advantage of array is we can represent multiple values with single variable.
- So the reusability of code improves, also readability is increases.
- If there is no array like structure we need to store many values in multiple variables, which is like just impossible for now a days programming.
- It is used to represent multiple data items of same type by using only single name.
- It can be used to implement other data structures like linked lists, stacks, queues, trees, graphs etc.
- 2D arrays are used to represent matrices.
Answered by
0
Answer:
Advantages and limitations of using structure over an array.
Explanation:
Advantages
- In an array, accessing a component exists very comfortable by utilizing the index number.
- The search function can be used to an array easily.
- 2D Array exists utilized to describe matrices.
- For any cause, a user desires to store considerable values of equivalent style then the Array can be used and utilized efficiently.
Limitations
- While expressing an array, the passing size of an array exists compulsory, and the size must be stable.
- There exists either lack or wastage of memory.
- Shifting exists needed for the insertion or omission of components in an array.
#SPJ2
Similar questions
Math,
6 months ago
Business Studies,
6 months ago
Social Sciences,
1 year ago
English,
1 year ago
Math,
1 year ago