Java实现学生管理系统(控制台版本)
前言介绍
最近很多同学找我帮忙做一些课程设计或Web前端大作业、其中控制台项目应该是初学者必须经历的一个过程、作为java初学者这个控制台版本的学生信息管理系统十分合适、用到的技术也是最简单的JavaList集合、变量的声明、对象的创建、一些基本的while语句、switch语句、循环遍历等基础语法。一个最基础版本的控制台学生管理系统也就是CRUD功能、 直接上完整代码
创建学生类Student
public class Student { private String id; private String name; private String arg; private String address; public String getId() { return id; } public void setId(String id) { this.id = id; } public String getName() { return name; } public void setName(String name) { this.name = name; } public String getArg() { return arg; } public void setArg(String arg) { this.arg = arg; } public String getAddress() { return address; } public void setAddress(String address) { this.address = address; }
main方法实现CRUD
package com.railway.modules.base.test; import java.util.ArrayList; import java.util.Scanner; public class TestStudent { public static void main(String[] args) { ArrayList<Student> array = new ArrayList<Student>(); while (true) { System.out.println("----------学生管理系统-----------"); System.out.println("---------1.查询学生信息---------"); System.out.println("---------2.添加学生信息---------"); System.out.println("---------3.删除学生信息---------"); System.out.println("---------4.修改学生信息---------"); System.out.println("---------5.输入你的选择---------"); Scanner input = new Scanner(System.in); int a = input.nextInt(); switch (a) { case 1: findAllStudent(array); break; case 2: addStudent(array); break; case 3: deleteStudent(array); break; case 4: updateStudent(array); break; case 5: default: System.out.println("谢谢你的使用"); System.exit(0); break; } } } }
查询方法
public static void findAllStudent(ArrayList<Student> array) { // TODO Auto-generated method stub if (array.size() == 0) { System.out.println("对不起,没有学生信息"); System.out.println("请重新选择"); return; } System.out.println("学号\t姓名\t年龄\t居住地"); for (int x = 0; x < array.size(); x++) { Student s = array.get(x); System.out.println(s.getId() + "\t" + s.getName() + "\t" + s.getArg() + "\t" + s.getAddress()); } }
添加方法
public static void addStudent(ArrayList<Student> array) { Scanner input = new Scanner(System.in); String id; while(true){ System.out.println("请输入你的学号"); id = input.nextLine(); // 判断ID是否重复; boolean flag = false; // 遍历集合信息 for (int x = 0; x < array.size(); x++) { Student st = array.get(x); // 取得该学生id与数组中id进行对比 if (st.getId().equals(id)) { flag = true; break; } } if (flag) { System.out.println("对不起,学号被占用"); }else{ break; } } System.out.println("请输入你的姓名"); String name = input.nextLine(); System.out.println("请输入你的年龄"); String arg = input.nextLine(); System.out.println("请输入你的地址"); String address = input.nextLine(); Student s = new Student(); s.setId(id); s.setName(name); s.setArg(arg); s.setAddress(address); array.add(s); System.out.println("添加成功"); }
删除方法
public static void deleteStudent(ArrayList array) { System.out.println("请输入你想删除学生的学号"); Scanner input = new Scanner(System.in); String id = input.nextLine(); int index = -1; for (int i = 0; i < array.size(); i++) { Student s = (Student) array.get(i); if (s.getId().equals(id)) { index = i; } } }
修改方法
public static void updateStudent(ArrayList<Student> array) { // TODO Auto-generated method stub Scanner input = new Scanner(System.in); System.out.println("请输入你要修改的学号"); String id = input.nextLine(); int index = -1; //变量集合 for (int i = 0; i < array.size(); i++) { //获取所有学生对象 Student s = array.get(i); if (s.getId().equals(id)) { index = i; break; } } if (index == -1) { System.out.println("不好意思,你要修改的学生信息不存在"); } else { System.out.println("请输入学生姓名"); String name = input.nextLine(); System.out.println("请输入学生年龄"); String arg = input.nextLine(); System.out.println("请输入学生地址"); String address = input.nextLine(); //创建学生对象 Student s = new Student(); s.setId(id); s.setId(name); s.setArg(arg); s.setAddress(address); //修改集合中的学生对象 array.set(index, s); System.out.println("修改学生成功"); } }
控制台打印
"C:\Program Files\Java\jdk1.8.0_51\bin\java" -Didea.launcher.port=7534 "-Didea.launcher.bin.path=D:\Program Files (x86)\JetBrains\IntelliJ IDEA 2016.3.6\bin" -Dfile.encoding=UTF-8 -classpath "C:\Program Files\Java\jdk1.8.0_51\jre\lib\charsets.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\deploy.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\access-bridge-64.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\cldrdata.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\dnsns.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\jaccess.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\jfxrt.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\localedata.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\nashorn.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\sunec.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\sunjce_provider.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\sunmscapi.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\sunpkcs11.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\ext\zipfs.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\javaws.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\jce.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\jfr.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\jfxswt.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\jsse.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\management-agent.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\plugin.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\resources.jar;C:\Program Files\Java\jdk1.8.0_51\jre\lib\rt.jar;C:\Users\Administrator\Desktop\Project to reconstruct\railway-admin\target\classes;C:\Users\Administrator\Desktop\Project to reconstruct\railway-admin;C:\Users\Administrator.m2\repository\cn\smallbun\screw\screw-core\1.0.5\screw-core-1.0.5.jar;C:\Users\Administrator.m2\repository\commons-logging\commons-logging\1.2\commons-logging-1.2.jar;C:\Users\Administrator.m2\repository\org\freemarker\freemarker\2.3.29\freemarker-2.3.29.jar;C:\Users\Administrator.m2\repository\org\slf4j\slf4j-api\1.7.30\slf4j-api-1.7.30.jar;C:\Users\Administrator.m2\repository\ch\qos\logback\logback-classic\1.2.3\logback-classic-1.2.3.jar;C:\Users\Administrator.m2\repository\ch\qos\logback\logback-core\1.2.3\logback-core-1.2.3.jar;C:\Users\Administrator.m2\repository\org\bouncycastle\bcprov-jdk16\1.46\bcprov-jdk16-1.46.jar;C:\Users\Administrator.m2\repository\org\apache\poi\poi\3.9\poi-3.9.jar;C:\Users\Administrator.m2\repository\org\apache\poi\poi-ooxml\3.17\poi-ooxml-3.17.jar;C:\Users\Administrator.m2\repository\org\apache\poi\poi-ooxml-schemas\3.17\poi-ooxml-schemas-3.17.jar;C:\Users\Administrator.m2\repository\org\apache\xmlbeans\xmlbeans\2.6.0\xmlbeans-2.6.0.jar;C:\Users\Administrator.m2\repository\stax\stax-api\1.0.1\stax-api-1.0.1.jar;C:\Users\Administrator.m2\repository\com\github\virtuald\curvesapi\1.04\curvesapi-1.04.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-starter\2.2.4.RELEASE\spring-boot-starter-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot\2.2.4.RELEASE\spring-boot-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-starter-logging\2.2.4.RELEASE\spring-boot-starter-logging-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\apache\logging\log4j\log4j-to-slf4j\2.12.1\log4j-to-slf4j-2.12.1.jar;C:\Users\Administrator.m2\repository\org\apache\logging\log4j\log4j-api\2.12.1\log4j-api-2.12.1.jar;C:\Users\Administrator.m2\repository\org\slf4j\jul-to-slf4j\1.7.30\jul-to-slf4j-1.7.30.jar;C:\Users\Administrator.m2\repository\jakarta\annotation\jakarta.annotation-api\1.3.5\jakarta.annotation-api-1.3.5.jar;C:\Users\Administrator.m2\repository\org\yaml\snakeyaml\1.25\snakeyaml-1.25.jar;C:\Users\Administrator.m2\repository\org\hamcrest\hamcrest\2.1\hamcrest-2.1.jar;C:\Users\Administrator.m2\repository\net\bytebuddy\byte-buddy\1.10.6\byte-buddy-1.10.6.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-core\5.2.3.RELEASE\spring-core-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-jcl\5.2.3.RELEASE\spring-jcl-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-starter-web\2.2.4.RELEASE\spring-boot-starter-web-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-starter-json\2.2.4.RELEASE\spring-boot-starter-json-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\com\fasterxml\jackson\datatype\jackson-datatype-jdk8\2.10.2\jackson-datatype-jdk8-2.10.2.jar;C:\Users\Administrator.m2\repository\com\fasterxml\jackson\datatype\jackson-datatype-jsr310\2.10.2\jackson-datatype-jsr310-2.10.2.jar;C:\Users\Administrator.m2\repository\com\fasterxml\jackson\module\jackson-module-parameter-names\2.10.2\jackson-module-parameter-names-2.10.2.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-starter-tomcat\2.2.4.RELEASE\spring-boot-starter-tomcat-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\apache\tomcat\embed\tomcat-embed-core\9.0.30\tomcat-embed-core-9.0.30.jar;C:\Users\Administrator.m2\repository\org\apache\tomcat\embed\tomcat-embed-el\9.0.30\tomcat-embed-el-9.0.30.jar;C:\Users\Administrator.m2\repository\org\apache\tomcat\embed\tomcat-embed-websocket\9.0.30\tomcat-embed-websocket-9.0.30.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-starter-validation\2.2.4.RELEASE\spring-boot-starter-validation-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\jakarta\validation\jakarta.validation-api\2.0.2\jakarta.validation-api-2.0.2.jar;C:\Users\Administrator.m2\repository\org\hibernate\validator\hibernate-validator\6.0.18.Final\hibernate-validator-6.0.18.Final.jar;C:\Users\Administrator.m2\repository\org\jboss\logging\jboss-logging\3.4.1.Final\jboss-logging-3.4.1.Final.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-web\5.2.3.RELEASE\spring-web-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-webmvc\5.2.3.RELEASE\spring-webmvc-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-expression\5.2.3.RELEASE\spring-expression-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-starter-aop\2.2.4.RELEASE\spring-boot-starter-aop-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-aop\5.2.3.RELEASE\spring-aop-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\aspectj\aspectjweaver\1.9.5\aspectjweaver-1.9.5.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-context-support\5.2.3.RELEASE\spring-context-support-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-beans\5.2.3.RELEASE\spring-beans-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-context\5.2.3.RELEASE\spring-context-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-starter-data-redis\2.2.4.RELEASE\spring-boot-starter-data-redis-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\data\spring-data-redis\2.2.4.RELEASE\spring-data-redis-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\data\spring-data-keyvalue\2.2.4.RELEASE\spring-data-keyvalue-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\data\spring-data-commons\2.2.4.RELEASE\spring-data-commons-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-tx\5.2.3.RELEASE\spring-tx-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-oxm\5.2.3.RELEASE\spring-oxm-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\io\lettuce\lettuce-core\5.2.1.RELEASE\lettuce-core-5.2.1.RELEASE.jar;C:\Users\Administrator.m2\repository\io\netty\netty-common\4.1.45.Final\netty-common-4.1.45.Final.jar;C:\Users\Administrator.m2\repository\io\netty\netty-handler\4.1.45.Final\netty-handler-4.1.45.Final.jar;C:\Users\Administrator.m2\repository\io\netty\netty-buffer\4.1.45.Final\netty-buffer-4.1.45.Final.jar;C:\Users\Administrator.m2\repository\io\netty\netty-codec\4.1.45.Final\netty-codec-4.1.45.Final.jar;C:\Users\Administrator.m2\repository\io\netty\netty-transport\4.1.45.Final\netty-transport-4.1.45.Final.jar;C:\Users\Administrator.m2\repository\io\netty\netty-resolver\4.1.45.Final\netty-resolver-4.1.45.Final.jar;C:\Users\Administrator.m2\repository\io\projectreactor\reactor-core\3.3.2.RELEASE\reactor-core-3.3.2.RELEASE.jar;C:\Users\Administrator.m2\repository\org\reactivestreams\reactive-streams\1.0.3\reactive-streams-1.0.3.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-configuration-processor\2.2.4.RELEASE\spring-boot-configuration-processor-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\com\baomidou\mybatis-plus-boot-starter\3.3.1\mybatis-plus-boot-starter-3.3.1.jar;C:\Users\Administrator.m2\repository\com\baomidou\mybatis-plus\3.3.1\mybatis-plus-3.3.1.jar;C:\Users\Administrator.m2\repository\com\baomidou\mybatis-plus-extension\3.3.1\mybatis-plus-extension-3.3.1.jar;C:\Users\Administrator.m2\repository\com\baomidou\mybatis-plus-core\3.3.1\mybatis-plus-core-3.3.1.jar;C:\Users\Administrator.m2\repository\com\baomidou\mybatis-plus-annotation\3.3.1\mybatis-plus-annotation-3.3.1.jar;C:\Users\Administrator.m2\repository\com\github\jsqlparser\jsqlparser\3.1\jsqlparser-3.1.jar;C:\Users\Administrator.m2\repository\org\mybatis\mybatis\3.5.3\mybatis-3.5.3.jar;C:\Users\Administrator.m2\repository\org\mybatis\mybatis-spring\2.0.3\mybatis-spring-2.0.3.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-autoconfigure\2.2.4.RELEASE\spring-boot-autoconfigure-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\boot\spring-boot-starter-jdbc\2.2.4.RELEASE\spring-boot-starter-jdbc-2.2.4.RELEASE.jar;C:\Users\Administrator.m2\repository\com\zaxxer\HikariCP\3.4.2\HikariCP-3.4.2.jar;C:\Users\Administrator.m2\repository\org\springframework\spring-jdbc\5.2.3.RELEASE\spring-jdbc-5.2.3.RELEASE.jar;C:\Users\Administrator.m2\repository\mysql\mysql-connector-java\8.0.17\mysql-connector-java-8.0.17.jar;C:\Users\Administrator.m2\repository\com\oracle\ojdbc6\11.2.0.3\ojdbc6-11.2.0.3.jar;C:\Users\Administrator.m2\repository\com\microsoft\sqlserver\sqljdbc4\4.0\sqljdbc4-4.0.jar;C:\Users\Administrator.m2\repository\org\postgresql\postgresql\42.2.9\postgresql-42.2.9.jar;C:\Users\Administrator.m2\repository\com\alibaba\druid-spring-boot-starter\1.1.13\druid-spring-boot-starter-1.1.13.jar;C:\Users\Administrator.m2\repository\com\alibaba\druid\1.1.13\druid-1.1.13.jar;C:\Users\Administrator.m2\repository\org\quartz-scheduler\quartz\2.3.0\quartz-2.3.0.jar;C:\Users\Administrator.m2\repository\com\mchange\mchange-commons-java\0.2.11\mchange-commons-java-0.2.11.jar;C:\Users\Administrator.m2\repository\commons-lang\commons-lang\2.6\commons-lang-2.6.jar;C:\Users\Administrator.m2\repository\commons-fileupload\commons-fileupload\1.2.2\commons-fileupload-1.2.2.jar;C:\Users\Administrator.m2\repository\commons-io\commons-io\2.5\commons-io-2.5.jar;C:\Users\Administrator.m2\repository\commons-codec\commons-codec\1.10\commons-codec-1.10.jar;C:\Users\Administrator.m2\repository\commons-configuration\commons-configuration\1.10\commons-configuration-1.10.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-core\1.4.0\shiro-core-1.4.0.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-lang\1.4.0\shiro-lang-1.4.0.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-cache\1.4.0\shiro-cache-1.4.0.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-crypto-hash\1.4.0\shiro-crypto-hash-1.4.0.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-crypto-core\1.4.0\shiro-crypto-core-1.4.0.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-crypto-cipher\1.4.0\shiro-crypto-cipher-1.4.0.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-config-core\1.4.0\shiro-config-core-1.4.0.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-config-ogdl\1.4.0\shiro-config-ogdl-1.4.0.jar;C:\Users\Administrator.m2\repository\commons-beanutils\commons-beanutils\1.9.3\commons-beanutils-1.9.3.jar;C:\Users\Administrator.m2\repository\commons-collections\commons-collections\3.2.2\commons-collections-3.2.2.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-event\1.4.0\shiro-event-1.4.0.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-spring\1.4.0\shiro-spring-1.4.0.jar;C:\Users\Administrator.m2\repository\org\apache\shiro\shiro-web\1.4.0\shiro-web-1.4.0.jar;C:\Users\Administrator.m2\repository\io\jsonwebtoken\jjwt\0.7.0\jjwt-0.7.0.jar;C:\Users\Administrator.m2\repository\com\fasterxml\jackson\core\jackson-databind\2.10.2\jackson-databind-2.10.2.jar;C:\Users\Administrator.m2\repository\com\github\axet\kaptcha\0.0.9\kaptcha-0.0.9.jar;C:\Users\Administrator.m2\repository\com\jhlabs\filters\2.0.235\filters-2.0.235.jar;C:\Users\Administrator.m2\repository\io\springfox\springfox-swagger2\2.7.0\springfox-swagger2-2.7.0.jar;C:\Users\Administrator.m2\repository\io\swagger\swagger-annotations\1.5.13\swagger-annotations-1.5.13.jar;C:\Users\Administrator.m2\repository\io\swagger\swagger-models\1.5.13\swagger-models-1.5.13.jar;C:\Users\Administrator.m2\repository\io\springfox\springfox-spi\2.7.0\springfox-spi-2.7.0.jar;C:\Users\Administrator.m2\repository\io\springfox\springfox-core\2.7.0\springfox-core-2.7.0.jar;C:\Users\Administrator.m2\repository\io\springfox\springfox-schema\2.7.0\springfox-schema-2.7.0.jar;C:\Users\Administrator.m2\repository\io\springfox\springfox-swagger-common\2.7.0\springfox-swagger-common-2.7.0.jar;C:\Users\Administrator.m2\repository\io\springfox\springfox-spring-web\2.7.0\springfox-spring-web-2.7.0.jar;C:\Users\Administrator.m2\repository\org\reflections\reflections\0.9.11\reflections-0.9.11.jar;C:\Users\Administrator.m2\repository\org\javassist\javassist\3.21.0-GA\javassist-3.21.0-GA.jar;C:\Users\Administrator.m2\repository\com\google\guava\guava\18.0\guava-18.0.jar;C:\Users\Administrator.m2\repository\com\fasterxml\classmate\1.5.1\classmate-1.5.1.jar;C:\Users\Administrator.m2\repository\org\springframework\plugin\spring-plugin-core\1.2.0.RELEASE\spring-plugin-core-1.2.0.RELEASE.jar;C:\Users\Administrator.m2\repository\org\springframework\plugin\spring-plugin-metadata\1.2.0.RELEASE\spring-plugin-metadata-1.2.0.RELEASE.jar;C:\Users\Administrator.m2\repository\org\mapstruct\mapstruct\1.1.0.Final\mapstruct-1.1.0.Final.jar;C:\Users\Administrator.m2\repository\io\springfox\springfox-swagger-ui\2.7.0\springfox-swagger-ui-2.7.0.jar;C:\Users\Administrator.m2\repository\com\qiniu\qiniu-java-sdk\7.2.23\qiniu-java-sdk-7.2.23.jar;C:\Users\Administrator.m2\repository\com\squareup\okhttp3\okhttp\3.14.6\okhttp-3.14.6.jar;C:\Users\Administrator.m2\repository\com\squareup\okio\okio\1.17.2\okio-1.17.2.jar;C:\Users\Administrator.m2\repository\com\aliyun\oss\aliyun-sdk-oss\2.8.3\aliyun-sdk-oss-2.8.3.jar;C:\Users\Administrator.m2\repository\org\apache\httpcomponents\httpclient\4.5.10\httpclient-4.5.10.jar;C:\Users\Administrator.m2\repository\org\jdom\jdom\1.1\jdom-1.1.jar;C:\Users\Administrator.m2\repository\com\qcloud\cos_api\4.4\cos_api-4.4.jar;C:\Users\Administrator.m2\repository\org\apache\httpcomponents\httpcore\4.4.13\httpcore-4.4.13.jar;C:\Users\Administrator.m2\repository\org\apache\httpcomponents\httpmime\4.5.10\httpmime-4.5.10.jar;C:\Users\Administrator.m2\repository\org\json\json\20140107\json-20140107.jar;C:\Users\Administrator.m2\repository\junit\junit\4.12\junit-4.12.jar;C:\Users\Administrator.m2\repository\org\hamcrest\hamcrest-core\2.1\hamcrest-core-2.1.jar;C:\Users\Administrator.m2\repository\joda-time\joda-time\2.9.9\joda-time-2.9.9.jar;C:\Users\Administrator.m2\repository\com\google\code\gson\gson\2.8.5\gson-2.8.5.jar;C:\Users\Administrator.m2\repository\com\alibaba\fastjson\1.2.72\fastjson-1.2.72.jar;C:\Users\Administrator.m2\repository\cn\hutool\hutool-all\4.1.1\hutool-all-4.1.1.jar;C:\Users\Administrator.m2\repository\org\projectlombok\lombok\1.18.4\lombok-1.18.4.jar;C:\Users\Administrator.m2\repository\io\minio\minio\8.0.3\minio-8.0.3.jar;C:\Users\Administrator.m2\repository\com\carrotsearch\thirdparty\simple-xml-safe\2.7.1\simple-xml-safe-2.7.1.jar;C:\Users\Administrator.m2\repository\com\fasterxml\jackson\core\jackson-annotations\2.10.2\jackson-annotations-2.10.2.jar;C:\Users\Administrator.m2\repository\com\fasterxml\jackson\core\jackson-core\2.10.2\jackson-core-2.10.2.jar;D:\Program Files (x86)\JetBrains\IntelliJ IDEA 2016.3.6\lib\idea_rt.jar" com.intellij.rt.execution.application.AppMain com.railway.modules.base.test.TestStudent
----------学生管理系统-----------
---------1.查询学生信息---------
---------2.添加学生信息---------
---------3.删除学生信息---------
---------4.修改学生信息---------
---------5.输入你的选择---------
1
对不起,没有学生信息
请重新选择
----------学生管理系统-----------
---------1.查询学生信息---------
---------2.添加学生信息---------
---------3.删除学生信息---------
---------4.修改学生信息---------
---------5.输入你的选择---------
2
请输入你的学号
1
请输入你的姓名
2
请输入你的年龄
3请输入你的地址
4添加成功
----------学生管理系统-----------
---------1.查询学生信息---------
---------2.添加学生信息---------
---------3.删除学生信息---------
---------4.修改学生信息---------
---------5.输入你的选择---------
以上就是Java实现学生管理系统(控制台版本)的详细内容,更多关于Java学生管理系统的资料请关注脚本之家其它相关文章!
最新评论