package _04_构造方法;

import java.util.Scanner;

public class UserTest {
    public static void main(String[] args) {
        // 1 通过键盘录入用户信息
        Scanner scanner = new Scanner(System.in);
        System.out.println("请录入用户名");
        String username = scanner.next();
        System.out.println("请录入密码");
        String password = scanner.next();
        System.out.println("请再次输入密码");
        String confirmPassword = scanner.next();
        System.out.println("请输入邮箱");
        String email = scanner.next();
        System.out.println("请输入性别");
        String gender = scanner.next();
        System.out.println("请输入年龄");
        int age = scanner.nextInt();

        // 调用注册方法
        // 注册方法在User 类 public
        User user = new User();
        user.register(username,password,confirmPassword,email,gender,age);

    }
}
