Search:

Type: Posts; User: javapenguin

Search: Search took 0.10 seconds.

  1. Replies
    13
    Views
    2,877

    [SOLVED] Re: Using Arrays to make a scoring program

    Ahhhhh...I see what copeg is getting at. You could make a Team class that keeps track of the score for that Team.

    //code removed by moderator

    I'm hoping that no two schools have the exact same...
  2. Replies
    13
    Views
    2,877

    [SOLVED] Re: Using Arrays to make a scoring program

    Also, I was wrong. Your name array won't be lost. What will be lost however will be the number of schools you got in getNumberOfSchools(). If you changed the return type to int, then

    names =...
  3. Replies
    13
    Views
    2,877

    [SOLVED] Re: Using Arrays to make a scoring program

    For tallying up the scores, parallel arrays would be a good idea.

    Make an index, say index 0, for a school in a String array.

    Then make a bunch of int arrays to store scores for each category...
  4. Replies
    13
    Views
    2,877

    [SOLVED] Re: Using Arrays to make a scoring program

    Your getSchoolNames should be of type String[].

    You're storing them but since names in just defined inside that method, it goes out of scope when that method ends.
  5. Replies
    13
    Views
    2,877

    [SOLVED] Re: Using Arrays to make a scoring program

    Void methods don't return anything.

    The values entered will be lost when you exit the method.

    Unless you change the return type to int or String or whatever you need to.
Results 1 to 5 of 5