呵呵,我刚开始学,不懂别的,所以写了一个比较hashCode的,大家有的跟帖啊

解决方案 »

  1.   

    下面的是糯米猪的程序:
    //Just make a friend...
    import javax.swing.JOptionPane;
    class Name{
      public static void main(String[] args){
         String name;
         name=JOptionPane.showInputDialog("Hey My name is Herro!"+"What is your name?");
          if (name==null){
            JOptionPane.showMessageDialog(null,"Oh...Bye!");
            System.exit(0);
          }
          else if(name.equals("") ){
             JOptionPane.showMessageDialog(null,"You don't want to make friend with me?");
            System.exit(0);}
            else{
              JOptionPane.showMessageDialog(null,"Ok Nice to meet you "+name+ "!!");
              System.exit(0);        }
          }  }//^(oo)^