//
// Created by zhang on 2024/12/8.
//
#include <stdio.h>
#include <stdbool.h>
#include <windows.h>
#include "function.h"
#include "myerror.h"
#include "extern.h"

int main() {
    SetConsoleOutputCP(65001);
    int isStudent;
    while (true) {
        fprintf(stdout, "欢迎进入口算系统！\n\n输入1以登录\n输入2以注册");
        int x;
        scanf("%d", &x);
        if (x == 1) {
            isStudent = Login();
            if (isStudent == 1 || isStudent == 0)break;
            if (isStudent == -1)continue;
        } else if (x == 2) {
            //UserSignin();
            clear();
        } else {
            //Error_Invalid_input();
        }
    }
    if (isStudent) {
        //StudentsDesktop();
    } else {
        //TeachersDesktop();
    }
}
