Difference between collection and arrays

Write the difference between collection and arrays?

E

Expert

Verified

a.) Array:

  • In this one need to give the size of the array during its declaration.
  • Array could not be adjusted dynamically.
  • The members of the array must be of the similar data type.


b.) Collection:

  • The size of the collection can be resized dynamically, according to the user's requirement.
  • Collection does not have permanent size.
  • It could have elements of dissimilar types.

 

   Related Questions in Programming Languages

©TutorsGlobe All rights reserved 2022-2023.