⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pmain.c

📁 排行榜中存放玩家信息和成绩
💻 C
字号:
/*Pmain.c:系统功能选择界面*/
#include<stdlib.h>
#include<stdio.h>
/*玩家结构体类型头文件*/
#include "score.h"
/*开始和进行游戏过程*/
#include "start.c"
/*按游戏成绩排序浏览排行榜*/
#include "sort.c"
/*帮助*/
#include "help.c"
/*按玩家姓名排序浏览排行榜*/
#include "sname.c"
/*清除排行榜*/
#include "clear.c"
void main()
{
int choice=0;
while(1)
    {
    clrscr();
    printf("#================================#\n");
    printf("#  Welcome to GuessNum Program!  #\n");
    printf("#================================#\n");
    printf("#  1 to start game               #\n");
    printf("#  2 to browse the sort by score #\n");
    printf("#  3 to browse the sort by name  #\n");
    printf("#  4 to view the help            #\n");
    printf("#  5 to clear the sort           #\n");
    printf("#  0 to exit                     #\n");
    printf("#================================#\n");
    printf("please input your choice here:");
    scanf("%d",&choice);
    getchar();
    switch(choice)
        {
        case 1:
            StartProgram();
            break;
        case 2:
            SortByScore();
            break;
        case 3:
            SortByName();
            break;
        case 4:
            PrintHelp();
            continue;
        case 5:
            ClearSort();
            break;
        case 0:
            exit(0);
            break;
        default:
            break;
        }
    }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -