home

http://itc206.wikispaces.com/Assignment+1 package javaapplication1;

/** public class Mess {
 * @author 11505419
 * @author 11505419

public static void main(String[] args) {

String s = javax.swing.JOptionPane.showInputDialog("Name"); //javax.swing.JOptionPane.showMessageDialog(null, s);

// if (s.equals("Yes")) { // (

//javax.swing.JOptionPane.showMessageDialog(null, "10"))

// } int n = javax.swing.JOptionPane.showConfirmDialog(null, "Would you like green eggs and ham?", "An Inane Question", javax.swing.JOptionPane.YES_NO_OPTION); // javax.swing.JOptionPane.showMessageDialog(null, "" + n);

if (n == 0) { javax.swing.JOptionPane.showMessageDialog(null, "Yes"); } if (n == 1) { javax.swing.JOptionPane.showMessageDialog(null, "No"); } } }