• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

arraylists

 
bouchra elmoustaine
Greenhorn
Posts: 1
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello
i'm new in java programming and i'm actually asked to do a project about movie management, in which i have to use array lists

this is something new for me as it was not part of the course, and i'm having difficulties understanding its concept and how i can implement it in this project, the problem is that it is due within 2 weeks :-(

if anyone can help, i would be more than glad

thank you
 
Shaan Shar
Ranch Hand
Posts: 1249
Java Spring Ubuntu
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Dear

First of all till now your requirement is not very much clear whether you are searching for the code or you have confusion regarding ArrayList.

What can I do for you is explain ArrayList.

Dear Arraylist is same as array you might have used earlier in C,C++ but the important difference is that size of ArrayList grows dynamically based on need.

It's a part of Legacy Collection Class in JAVA from Sun.

More you can find on the below link

Collections


 
Ernest Friedman-Hill
author and iconoclast
Marshal
Pie
Posts: 24204
34
Chrome Eclipse IDE Mac OS X
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
An ArrayList is nothing like an array in C or C++. It's like a vector<void *> in C++, I suppose.

An ArrayList is not a "legacy collection". It replaces Vector, which is considered a legacy collection.

And, mein gott, what kind of a reference is that to give someone new to Java? here is a tutorial on using and understanding the Collections classes (ArrayList is one.)
 
Stan James
(instanceof Sidekick)
Ranch Hand
Posts: 8791
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When starting a complex assignment, it's smart to start with the smallest possible part of the code you can imagine. Write and test just a few lines of code. Then add and test a few more. Every few minutes you have some amount of running, tested code that you can actually turn in for your assignment. Sweet.

List out all the things your program has to do and pick one very simple item. Talk to us about your choice here and we'll see if we can get you going.

This sounds like odd advice the first time you hear it, but consider the opposite ... design and write hundreds of lines of code without being sure any of it works then hope for the best when you finally start it up. That's scary!
[ March 21, 2006: Message edited by: Stan James ]
 
Henry Wong
author
Marshal
Pie
Posts: 20829
75
C++ Chrome Eclipse IDE Firefox Browser Java jQuery Linux VI Editor Windows
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This sounds like odd advice the first time you hear it, but consider the opposite ... design and write hundreds of lines of code without being sure any of it works then hope for the best when you finally start it up. That's scary!


I would like to add that many very good and experienced developers work with tight code/compile/test cycles. This suggestion isn't just for the newbie. IMHO, it should be considered a "best practice".

Henry
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic