i want the program to choose randomely choose an animal(i didn't list them all as there are 15) then answere the 5 questions given (i.e. the questions on labels 1, 3 ,5 ,7 and 9) and answere them depending on the animal (in the if statements in the actionPerformed method). then string "p" gets given the value of the animal (again, in the if statements). then, the labels (both questions and answeres) get shown and the user has to select an animal(using the combo box)
if the animal is the same as the user selected then they win, else they lose.
i made one modification:
q11.setText(p);
}
public void itemStateChanged(ItemEvent e){
cc.setEnabled(false);
if( cc.getSelectedItem()== q11.getText()){
but it always seems to chose the same number (thus, the same animal) and it complains that "variable p may not have been intialized".
hope that helps you help me
