File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Programming Diversions and the fly likes Iterator for an array Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of JavaScript Promises Essentials this week in the JavaScript forum!
JavaRanch » Java Forums » Other » Programming Diversions
Bookmark "Iterator for an array" Watch "Iterator for an array" New topic
Author

Iterator for an array

Akhilesh Trivedi
Ranch Hand

Joined: Jun 22, 2005
Posts: 1531
My friend sent me this code and asked me about the for loop there.


I said it will not work in 1.4 and though i bragged about enhanced-for loop in java 5., for the initial 2-3 mintues i was trying to fix an iterator for the variable 'list' even to put a breaking-point of hasNext() as the 'for condition'.

Only later i realaized... list was not a List... it was array.
[ January 17, 2008: Message edited by: Akhilesh Trivedi ]

Keep Smiling Always — My life is smoother when running silent. -paul
[FAQs] [Certification Guides] [The Linux Documentation Project]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Iterator for an array