Java 实现会员注册升级 关键代码

    	  String a="注册成功!";
    	  boolean b=false;
    	  String[] splitphone=new String [3]; 
    	  splitphone=dian.split("-",2);
    	  if(shen.length()!=16&&shen.length()!=18){
    		  System.out.println("身份证号必须是16位或是18位!");
    	  }else if(shou.length()!=11){
    		  System.out.println("手机号码必须是11位!");
    	  }else if(splitphone[0].length()!=4&&splitphone[0].length()!=7){
    		  System.out.println("座机号码区号必须是四位,电话号码必须是七位!");
    	  }else{    		 
    		  b=true;
    	  }
    	  return a;
      

******************/*/*/*/*/
                Scanner input =new Scanner (System.in);
		hui h=new hui();		
		String a,b1,b2;
		String w;
		System.out.println("***欢迎进入注册系统***");
		do{
			System.out.println("请输入身份证号:");
			a=input.next();
			System.out.println("请输入手机号:");
			b1=input.next();
			System.out.println("请输入座机号:");
			b2=input.next();
			w=h.zhuce(a,b1,b2);
			System.out.println(w);		
		}while(!w.equals("注册成功!"));

	}

你可能感兴趣的:(Java 实现会员注册升级 关键代码)