Home > Software engineering >  45. Obj: error LNK2001: unresolved external symbol "protected: int __thiscall st
45. Obj: error LNK2001: unresolved external symbol "protected: int __thiscall st

Time:10-06

 # include 
#include
#include
#include
The class student
{
Protected:
Int number;//student id
Int the PWD.//
char name[20];//name
Char sex [6].//gender
Char place [20].//native
Char nation [6].//national
Char birth [20].//date of birth
Int the find (student * * p, int num, char department, char classname, char name, char * pn="^");
Char party [10].//political landscape
Char id [20]; Id//
Char classname [20].//class name
Char telnumber [20].
Char department [20].//college name
Float score [3].//achievement
Public:
Student * next;
Student () {}
~ student () {}
Char * getname () {return name; }
Char * getclassname () {return classname. }
Char * getdepartment () {return department; }
Int getnumber () {return number; }
Int getpwd () {return PWD; }
Float getscore (int I) {return score [I]; }
Float getg () {return (score score [0] + [1] + score [2]). }
//input information
Void input ()
{
Int e=1;
Cout<& lt;" According to the prompt: "& lt; Cout<& lt;" Please enter the school name: "& lt; cin> Department;
Cout<& lt;" Please enter the class: "& lt; cin> The classname.
Cout<& lt;" Please enter a number: ";
cin> Number;
Cout<& lt;" Please input your name: ";
cin> The name;
Do
{
Cout<& lt;" Please enter the gender: ";
cin> Sex;
If (STRCMP (sex, "male")==0 | | STRCMP (sex, "female")==0)
{
Cout<& lt;" Please enter the phone number: ";
cin> Telnumber;
Cout<& lt;" Please enter a domicile of origin: ";
cin> Place;
Cout<& lt;" Please enter the nation: ";
cin> The nation;
Cout<& lt;" Please enter the birthday: ";
cin> Birth;
Cout<& lt;" Please enter the political landscape: ";
cin> Party;
Cout<& lt;" Please enter the id number: ";
cin> Id;
Cout<& lt;" Please enter the math score: ";
cin> Score [0].
Cout<& lt;" Please enter the English score: ";
cin> Score [1].
Cout<& lt;" Please enter the computer score: ";
cin> Score [2].
E=0;
}
The else
{
Cout<& lt;" Without this type of gender! Enter again!" E=1;
}
} while (e);
return ;
}
Void input (ifstream & amp; Is)
{
Is> Department> Classname> Number> Name> Sex> Telnumber> Place> Nation> Birth> Party> Id
> Score [0] & gt;> Score [1] & gt;> Score [2].
Is the get ();
}
//password
Void password ()
{
int i=0;
Int the PWD, key=123456;//assume that the password is 123456
Do
{
If (I.=0)
Cout<& lt;" Wrong password!" Cout<& lt;" The first "& lt; cin> The PWD.
} while (PWD!=key& & + + i<3);
If (I==3)
Cout<& lt;" Password mistake, three chances already finished!" The else
Cout<& lt;" Please choose 1 or 2 to modify the message, "& lt; }
//xiugai
Void domend ()
{student * p;
Int num=1, n.
char name[20];
Char classname [20].
Char department [20].
Do
{cout<& lt;" 1: according to the number change, 2: according to the name change: ";
cin> n;
} while (n<1 | | n> 2);
If (n==1)
{
Cout<& lt;" Please enter a number: ";
cin> Num.
}
If (n==2)
{
Cout<& lt;" Please input your name: ";
cin> The name;
}
If (! Find (& amp; P, num, name [20], department [20], the classname [20]))
{
Cout<& lt;" SORRY! Can't find you want to modify content!" return;
}
}
//display information
Void the output ()
{
Cout<& lt;" Students basic information is as follows: "& lt; Cout<& lt;" School name: "& lt; <& lt;" The class name: "& lt; <& lt;" Number: "& lt; <& lt;" Name: "& lt; <& lt;" Gender: "& lt; <& lt;" Phone number: "& lt; <& lt;" Native place: "& lt; <& lt;" Ethnic composition: "& lt; <& lt;" Birthday: "& lt; <& lt;" Political landscape: "& lt; <& lt;" Id number: "& lt; <& lt;" Mathematics: "& lt; <& lt;" English: "& lt; <& lt;" Computer: "& lt; <& lt;" Total score: "& lt; }
Void the output (ofstream & amp; OS)
{
Os}
};

The class school
{
Public:
The school () {head=new student; The head - & gt; Next=NULL; Key=0; }
To school () {delete head; }
Void input ();//input function
Void mend ();//modify function
Void del ();//delete function
nullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnullnull
  • Related