Advertisement
Help Keep Boards Alive. Support us by going ad free today. See here: https://subscriptions.boards.ie/.
https://www.boards.ie/group/1878-subscribers-forum

Private Group for paid up members of Boards.ie. Join the club.
Hi all, please see this major site announcement: https://www.boards.ie/discussion/2058427594/boards-ie-2026

Opinions: ArrayList Vs. File IO

  • 02-10-2007 08:06AM
    #1
    Closed Accounts Posts: 364 ✭✭


    Hi Folks,
    Just wondering what peoples opinons were on using an ArrayList of up to 500 strings (of size no more than 10 chars).

    Is this too large? Should I use file IO for this instead? Would this be even slower when searching for an item as you would have to read the entire file each time,

    Thanks


Comments

  • Registered Users, Registered Users 2 Posts: 378 ✭✭sicruise


    That is only 5000 chars!

    Of course it'll much faster loaded into memory in an ArrayList format.


  • Closed Accounts Posts: 364 ✭✭Paligulus


    Cheers for that. That's what I though!!! For some reason I started thinking it was bad programming practice.


  • Registered Users, Registered Users 2 Posts: 378 ✭✭sicruise


    No problem :)


Advertisement