import javax.swing.*;
import java.awt.*;
public class ImageTutorial extends JFrame {
private ImageIcon image;
private JLabel label;
private ImageIcon mario;
private JLabel...
Type: Posts; User: kingsta
import javax.swing.*;
import java.awt.*;
public class ImageTutorial extends JFrame {
private ImageIcon image;
private JLabel label;
private ImageIcon mario;
private JLabel...
import javax.swing.JOptionPane;
public class circle{
//Instance variables
/*
* 2D array of chars for the board
*/
public static void main(String[] args)
/* *****************************************
AUTHOR
******************************************** */
import java.util.Arrays;
import javax.swing.*; // import the swing library for I/O
...
Ok will do this, another problem with my code is that after the first loop it keeps going to the else statement rather than doing the first if statement when i enter a valid painting :s any ideas?...
Hi I have this code that i've written, I was wondering how I would add 1 to my int[] scores array when a user inputs one of the paintings.
For example: If the user enters "Mona Lisa" it would add 1...
Yeah I want the loop to keep going till the user exits. Will loop the paintings and see how i get on thanks.
--- Update ---
I've tried that and I'm still have trouble :/ Im not sure where to...
/* *****************************************
AUTHOR
******************************************** */
import javax.swing.*; // import the swing library for I/O
import java.util.*;
public...
Ok thanks, i've fixed it
String user1 = JOptionPane.showInputDialog("Please enter the first player's name"); //Ask's for the user's name
String user2 = JOptionPane.showInputDialog("Please enter the second player's name");...
What would i type though?
I'm not sure i follow :S how would I pass the desired value to Tuna's constructor from my other class :S
String user1 = JOptionPane.showInputDialog("Please enter the first user's name");
JOptionPane.showMessageDialog(null, user1 + " will go first! good luck!");
and in my other class i have
...
public static void changedue()
{
String textinput;
String textinput1;
String value1;
int sale = 0;
int amount = 0;
int chnge = 0;
int f, twenty, ten, five, one;
double price;
import javax.swing.*; // import the swing library for I/O
class change
{
public static void main (String[] param)
{
changedue();
System.exit(0);
Hi,
I have to create a multiple choice quiz based bored game for an Assignment but I'm having some trouble. I've read over the internet that it would be easier to store the questions/answers in an...