Newbie Java array question

Status
You're currently viewing only jbode's posts. Click here to go back to viewing the entire thread.
Not open for further replies.

jbode

Ars Legatus Legionis
11,752
Subscriptor
Bagheera":9o11apv8 said:
Blacken00100":9o11apv8 said:
If you need to resize an array in the normal course of programming, however, that should be something of a warning flags.

Really? What if you're querying multiple tables in a database, or grabbing event logs from multiple servers, or grabbing looped input from a user? In each case, you don't know how many elements (how many rows, events, or inputted items) you'll eventually get. Is that a warning sign or just typical programming?

You don't use arrays for those situations; you use some sort of collection type that can be dynamically sized, such as a Vector or a List in Java.
 
Status
You're currently viewing only jbode's posts. Click here to go back to viewing the entire thread.
Not open for further replies.