Back

Explore Courses Blog Tutorials Interview Questions
0 votes
2 views
in Java by (6.5k points)
I find using simple arrays easier than Arraylists and I also feel like Arraylists are complicated for no reason. Are there any advantages to Arraylists?

1 Answer

0 votes
by (11.3k points)

There are major advantages to ArrayLists when real-world projects are concerned:

  • ArrayLists can be appended dynamically: ArrayLists do not have to have a definite memory allocation like normal arrays when they are declared, they can be appended upon runtime. This saves unnecessary memory usage by the program. 
  • The insertion and searching implementations of ArrayLists are stronger than normal arrays and provide more efficiency. 

    

If you're looking to learn java, practicing with ArrayLists over normal arrays will give you a lot of competitive and practical edge in the subject matter. 

Related questions

0 votes
1 answer
0 votes
1 answer
0 votes
1 answer
asked Nov 25, 2019 in Java by Anvi (10.2k points)
0 votes
1 answer
0 votes
1 answer
asked Oct 31, 2019 in Java by Anvi (10.2k points)

Browse Categories

...