好文档 - 专业文书写作范文服务资料分享网站

c++单词学习软件课程设计报告(内附程序源代码)

天下 分享 时间: 加入收藏 我要投稿 点赞

附录:

源代码

#include #include #include #include #include #include #include #define NULL 0

int n;

struct word { char yw[20]; char zw[80];

struct word *next; };

struct wrongword { char en[20]; char ch[40]; char wrong[20]; struct wrongword *next; };

class user{ public: char username[20]; char password[20]; user(char name[],char mm[]); int find(char name[]); void userregister(); void userjudge(); char custom(); char server1(); char server2(); friend char continueif(); friend int user_long(long ,char ); };

class words{ public: char english[20]; char chinese[40]; void words_get(char en[],char ch[]); void words_add(); void words_delete(); void words_revise(); void words_translate();

friend int words_long(long ,char aa[]); friend long words_seek(char ch[]); friend int words_long2(long ,char aa[]); //倒数 friend struct word * creat();

friend void writefile(struct word * ); };

class wordsgame{ public: void game_get(char en[]); int game_abc(); int game_tran(); void game_judge(); void wrongwords_add(); void wrongwords_examine(); void wordsgame::wrongwords_search(); struct wrongword *wrongwords_creat(); friend long wrongwords_seek(char en[]); friend int words_long(long ,char ); friend int wrongwords_long(long ,char aa); friend struct word *creat();

friend void print(struct word * ); friend int suiji(int num); };

int user_long(long z,char aa) {

int i=0; char bb;

ifstream llw(\ llw.seekg(z,ios::beg); do {

llw.seekg(z+i,ios::beg); llw.get(bb); i++;

}while(bb!=aa); llw.close(); return i-1; }

user::user(char name[],char mm[]) { strcpy(username,name); strcpy(password,mm); }

void user::userjudge() { if(find(username)!=1) { cout<<\用户名不存在!\ exit(-1); } else if(find(username)==1&&find(password)!=2) { cout<<\用户密码错误!\ exit(-1); } else { system(\ for(int i=10;i>=1;i--) { cout<<\欢迎您使用该软件\ cout<<\初始化中......\ _sleep(500); system(\ } system(\ //system(\ //system(\ cout<<\初始化成功...!\ _sleep(3000); //system(\ } }

int user::find(char name[]) //{ char hh; char na[20],na2[20]; long z=0,k=0; ifstream us(\ if(!us)

制作人:llw\查找用户

c++单词学习软件课程设计报告(内附程序源代码)

附录:源代码#include#include#include#i
推荐度:
点击下载文档文档为doc格式
8ggky8i59d8mqar1rud16ehs64cxmy011zk
领取福利

微信扫码领取福利

微信扫码分享