Search:

Type: Posts; User: K0209

Search: Search took 0.32 seconds.

  1. Re: Problems with File Reader (Strings and 2D Array Storage)

    This is my newest Code...

    I have methods at the bottom to sort and print the Winners (ArrayList)...I don;t know if they work because I still can't get them to store.



    package coursework1;
    ...
  2. Re: Problems with File Reader (Strings and 2D Array Storage)

    Ok, I thought this would work, but it didn't ><



    private static void printFile (String[]args) throws FileNotFoundException{
    //This will Print the file in its entirety.
    ...
  3. Re: Problems with File Reader (Strings and 2D Array Storage)

    I've been hitting my head against the wall with this today lol
    I've been experimenting with ArrayLists and 2D arrays.

    I feel a series of 2D arrays would work more in my favor...because the Array...
  4. Re: Problems with File Reader (Strings and 2D Array Storage)

    @MrE, an identity would be nice to put with the username :D
    As for the Blue Book, I have read it cover to cover. While it outlines it with the account example it contains too many variables specific...
  5. Re: Problems with File Reader (Strings and 2D Array Storage)

    Lol I did see the comments and did build upon them somewhat, however I partially thought that you may have removed them from the final product because they didn't work lol

    My basic 'idea' of how...
  6. Re: Problems with File Reader (Strings and 2D Array Storage)

    ^Kinda...
    I wonder if theres anyway to have the code you originally provided store every bit of 'cut' data in a standard array?
    Afterall, it has stored one set of data, even if it stored it all, I...
  7. Re: Problems with File Reader (Strings and 2D Array Storage)

    Sorry, I put in the ////////////'s to help me break up between methods and such...I must've left some in when I cropped. Unless your referring to the System.out.println("/////////////////"); That was...
  8. Re: Problems with File Reader (Strings and 2D Array Storage)

    Damn double post again, sorry!

    Okay, I tihnk I've managed to get this to store each array of data in an array list, however when I request the data all it prints is "[Ljava.lang.String;@1cfb549"...
  9. Re: Problems with File Reader (Strings and 2D Array Storage)

    ^DoH! Ofcourse, silly me!
    Ok, been working on it and I'm wondering which means would be better to reach an end:

    A: I create the following arrays for storage...
    Athlete (Strings) : To hold the...
  10. Re: Problems with File Reader (Strings and 2D Array Storage)

    Its probably just me being dense, but I can't seem to fit this into my code.
    While I have been able to call it, I'm a bit at a loss as to how I go about retrieving the various values and also to...
  11. Re: Problems with File Reader (Strings and 2D Array Storage)

    Naturally!
    Although I'd bet I'll be back for help before the end of the day! lol
  12. Re: Problems with File Reader (Strings and 2D Array Storage)

    Wow! You wrote that?!
    I wish I had that kinda know how here! ^__^

    If I'm honest, I love programming! I want to know all there is to it, but since I've only been studying for a short while I'm...
  13. Re: Problems with File Reader (Strings and 2D Array Storage)

    I have tried, do you think the method mentioned in my above edit 1.2 is a good way to go?
  14. Re: Problems with File Reader (Strings and 2D Array Storage)

    ^All he provided was the above... plus, he said "play with it". So he's either encouraging self discovery or for us to modify the code lol

    I think...(THINK) i'm getting there, if I count the...
  15. Re: Problems with File Reader (Strings and 2D Array Storage)

    ^I really like that idea. Sadly, my own knowledge is kinda holding me back here... I have changed my code and feel this time (finally) that I am on the right track... I have put in BOLD the area...
  16. Re: Problems with File Reader (Strings and 2D Array Storage)

    At the end of readTimes I called the method "Main2.displayHeatTimes(args);", this is a simple method that displays the all values in an array. Its worked on the dozens of other programs I have made...
  17. Re: Problems with File Reader (Strings and 2D Array Storage)

    ^Actually that's the whole code.
    I originally intended to use 2 Dimensional Arrays to store my info, and that code would've showed all the values in a 2D array.
    I kept it there as reference for...
  18. Re: Problems with File Reader (Strings and 2D Array Storage)

    Apologies for double posting... I'm making some head way with the program...
    However still having trouble getting and storing doubles (and data in general _;)

    Heres the newest code...


    ...
  19. Re: Problems with File Reader (Strings and 2D Array Storage)

    My intention is to produce a program that can read in a file with more than the standard heats and nos of athletes and print out the 'winners' from each heat.

    As I mentioned, as useful as the...
  20. Re: Problems with File Reader (Strings and 2D Array Storage)

    @teen-omar; no I wasn't told to specifically use the Scanner method and the code you have shown me is VERY useful for reading an ENTIRE document, but alas, my requirements are quite specific.

    I...
  21. Re: Problems with File Reader (Strings and 2D Array Storage)

    @copeg thanks for such a detailed reply ^^
    Hm you do have a point. It would be far better practice to design code that would be able to accept files of different names and with different number of...
  22. Replies
    3
    Views
    1,387

    Re: Good Morning/Day/Afternoon/Evening/Night

    Thank you very much for the warm welcome ^_^
    I posted my thread here: http://www.javaprogrammingforums.com/whats-wrong-my-code/2526-problems-file-reader-strings-2d-array-storage.html#post7620
    ...
  23. Problems with File Reader (Strings and 2D Array Storage)

    Okay. I apologise if this is in the wrong section ^^

    The assignment that I have been given asks me to use a .txt file (that contains 7 heats, each with 8 runners with their times, nationalities,...
  24. Replies
    3
    Views
    1,387

    Good Morning/Day/Afternoon/Evening/Night

    Damn, I really hate intro threads -- mainly because I've never written a decent one yet!

    Helloo my names Steve

    I signed up her mainly to get some new angles on this complex language ^_^
    I've...
Results 1 to 24 of 24