# include < iostream> using namespace std ; using std :: cout; using std :: cin; using std :: endl; class student{ public: bool ok; bool woman; bool instudy; int finalchoice ; int a; bool success; string name ; int grade ; int choice[9] ; student(){ instudy=false; ok= false ; success = true ; woman = true ; finalchoice = 0; a=1; } } int calcu(int ,int ,bool ,int , student [] ); void main (){ student students[800]; int s[]={60,80,40,40,40,60,50,80,5... int xx[9]; int yy[9]; for(int i=0; i<800; i++){ cout<<"enter student name "; cout<<" enter the student grade "; cin>> students.grade; cout<<" put the choices (1.......9)"; for(int j=0;j=9;j++){ cin>>students.choice[j]; } } int x=240,y=240; for(int k=1;k<=9;k++){ int fcounter = 0; int mcounter=0; for( int i=0;i<800; i++) if(students.choice-1==k) if(students.woman == true ){ Additional Details 47 minutes ago fcounter++; students.instudy=true;} else{ mcounter++; students.instudy=true;} int size=s[k-1]/2; x=calcu(fcounter,x,true,size,s... xx[k-1]=x; for (i=0; i<800;i++) { if (students.instudy==true) if(students.grade>=x) {students.ok=true; students.finalchoice=k; students.instudy=false;} else{students.a=students... + 1; } } y=calcu(mcounter,y,true,size,s... yy[k-1]=y; for (i=0; i<800;i++) { if (students.instudy==true) {if(students.grade>=y) {students.ok=true; students.finalchoice=k; students.instudy=false;} else{students.a=students[i]... + 1; } } } } } int calcu(int fmale,int x,bool gender,int size,student students[])//fmale=fcounter or mcounter { int fnumber=fmale; while (fnumber>size) { fnumber=0; for (int i=0;i<800;i++) {if (students[i].instudy==true) if(students[i].grade==x) fnumber++;} x--; } return x++; } [/i][/i][/i]
Why do you have Additional Details and 47 minutes ago there? This seems like the problem to me. If they are remarks, use // with them.
Seems like OP posted it in Yahoo answer and no one is doing his homework for free, so he copied and pasted the same project assignment here thinking someone will solve his project assignment
Exactly. He's even got truncated lines in there... eg: x=calcu(fcounter,x,true,size,s... I looked over it but generally ignore posts like the above, for two reasons: 1) I didn't go through university to do someone else's homework; and 2) if the OP can't even be bothered to post the code within the 'code' tags, why should I be bothered to read it?