Welcome to the Java Programming Forums
The professional, friendly Java community. 21,500 members and growing!
Members have full access to the forums. Advertisements are removed for registered users.
Last edited by Gugubo; November 30th, 2013 at 03:33 PM. Reason: Wrong section
Another way would be with a switch() statement.
If you don't understand my answer, don't ignore it, ask a question.
. . . or randomly choosing the index of a String array . . .