diff --git a/src/User.java b/src/User.java new file mode 100644 index 0000000..759d3ca --- /dev/null +++ b/src/User.java @@ -0,0 +1,70 @@ +import java.util.ArrayList; +import java.util.Scanner; +import java.io.IOException; + +public class User { + String username; + String password; + String level; + ArrayList list1 = new ArrayList<>(); + int state=1; + public boolean logon(){//登录 + if(state==1){ + try { + new ProcessBuilder("clear").inheritIO().start().waitFor(); + } catch (IOException | InterruptedException e) { + //e.printStackTrace(); + } +// try { +// Runtime.getRuntime().exec("cmd /c cls").waitFor(); +// } catch (IOException | InterruptedException e) { +// e.printStackTrace(); +// } + System.out.println("=== 中小学数学卷子自动生成程序 ==="); + System.out.println("请输入账户名称,密码:"); + } + Scanner sc=new Scanner(System.in); + String name=sc.next(); + String word=sc.next(); + for(int i=0;i