您的位置首页生活百科

No such file or directory

No such file or directory

的有关信息介绍如下:

No such file or directory

“No such file or directory”一般是指没有找到文件的位置应该在属性中将它找不到的文件的路径添加到包含目录那一列里。具体做法为:点击菜单“项目”-“属性”。在弹出的属性对话框中选择“常规”,在“附加包含目录”处添加它找不到的文件的路径。看一下的代码没有任何错误。同时,建议将scanf("%f\n",&r)里的\n去掉。改成scanf("%f",&r);class student { protected: int name; int individualStuNo; int score; public: student(); ~student(); void setindividualStuNo(int); void setname(int); void setscore(int); int GetindividaulStuNo(); int Getname(); int Getscore(); }; student::student() { individualStuNo=0; } student::~student(){} int student::Getname() { return name;} int student::GetindividaulStuNo() { return individualStuNo;} int student::Getscore() { return score;} void student::setname(int _name){this->name = _name;} void student::setscore(int _score){this->score = _score;} void student::setindividualStuNo(int _individualStuNo){this->individualStuNo = _individualStuNo;} #include using namespace std; int main() { student s1; student s2; student s3; student s4; cout<<"请输入下一个学生的姓名:"; int name; cin>>name; cout<<"请输入此学生的学号:"; int individualStuNo; cin>>individualStuNo; cout<<"请输入此学生的成绩:"; int score; cin>>score; s1.setname(name); s1.setindividualStuNo(individualStuNo); s1.setscore(score); int a,b,c;cout<<"请输入下一个学生的姓名:"; cin>>a; cout<<"请输入此学生的学号:"; cin>>b; cout<<"请输入此学生的成绩:"; cin>>c; s2.setname(a); s2.setindividualStuNo(b); s2.setscore(c); cout<<"请输入下一个学生的姓名:"; cin>>a; cout<<"请输入此学生的学号:"; cin>>b; cout<<"请输入此学生的成绩:"; cin>>c; s3.setname(a); s3.setindividualStuNo(b); s3.setscore(c); cout<<"请输入下一个学生的姓名:"; cin>>a; cout<<"请输入此学生的学号:"; cin>>b; cout<<"请输入此学生的成绩:"; cin>>c; s4.setname(a); s4.setindividualStuNo(b); s4.setscore(c); cout<<"姓名"<