celder01's Profile User Rating: -----

Reputation: 0 Apprentice
Group:
New Members
Active Posts:
2 (0 per day)
Joined:
01-February 13
Profile Views:
101
Last Active:
User is offline Feb 05 2013 12:38 PM
Currently:
Offline

Previous Fields

Dream Kudos:
0
Icon   celder01 has not set their status

Posts I've Made

  1. In Topic: Keep getting out of bounds error and not randomizing correctly

    Posted 3 Feb 2013

    View Postjon.kiparsky, on 02 February 2013 - 07:37 PM, said:

    It would be handy if you were to post the error message, so we could figure out where the problem is.

    Also, the section from line 110 where you determine the suit of the cards could be done a lot easier with the div and mod operators (/ and %).

    Hint: make an array with the names of the suits, and get the key for the array by integer division. Then scale the number with the modulo operator.


    Here is the error code, this does not always appear sometimes I will cycle through the program 3 or 4 times before this pops up:

    Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 13
    at cardWars.cardDisplay(cardWars.java:130)
    at cardWars.main(cardWars.java:32)

My Information

Member Title:
New D.I.C Head
Age:
Age Unknown
Birthday:
Birthday Unknown
Gender:

Contact Information

E-mail:
Private

Friends

celder01 hasn't added any friends yet.

Comments

celder01 has no profile comments yet. Why not say hello?