I am a little confused on Array's and wonder if someone could help me?
I have a two dimensional Array with 4 rows and 2 columns
int display[][]= new int[4][2];
Im a little confused about how to do the math and also use for statements with it. I have a survey that I am doing using two different options a ComboBox(foodJComboBox) and a Radiobutton(likeJRadioButton). The foodJComboBox choices comes from an array(one dimensional) that feeds the combo box.
I am trying to make the array have two columns one for like one for dislike and to display the numbers in there. array is display
Using both of those options for writing a for statement I am not able to figure it out. Any help would be greatly appreciated. Here is what I have come up with and am obviously at a loss.
int display[][]= new int[4][2]; for(likeJRadioButton=true; foodChoices = "Pizza"; pizzaLike++) { pizzaLike = display[0][0]+1 } for(dislikeJRadioButton = false; foodChoices = "Pizza"; pizzaDislike++) { pizzaDislike = display[0][1]+1 }
Can you please instruct me where I am going wrong?