Sunday, February 24, 2019

Final Project

Final advise Part 2(Worth 20% of your grade) Student Name James Keys Class/ sectionalization CMIS 102 Professor Name Jose Romero Assignment due date 11/4/12 // Which State. cpp include stdafx. h include <iostream> include < range> using namespace std int main() int x = 0 int found = 0 int imagine=0 bollocks up sum float aver progress int age10 string name10 string Find_State = string state10 string state_abbr10 bool okay = true do cout << Enter the family members name. display case through with(p) when complete. ltlt endl cin gtgt namecount if ( namecount == DONE namecount==done) okay = false break cout ltlt Enter family members age ltlt endl cin gtgt agecount cout ltlt Which state is ltlt namecount ltlt from? Type in CA, NY, TX, VA, VT? ltlt endl cin gtgt statecount if ( statecount == CA statecount == ca) statecount = California state_abbrcount = CA else if (statecount==TX statecount == tx) statecount = Texas tate_abbrcount = TX else if (statecount==V A statecount == va) statecount = Virginia state_abbrcount = VA else if (statecount==NY statecount == ny) statecount = New York state_abbrcount = NY else if (statecount==VT statecount == vt) statecount = Vermont state_abbrcount = VT else cout ltlt I dont understand ltlt endl count count++ while (okay count = 10) char yn= do cout << Do you wish to list people living in a certain state? << endl cin >> yn if ( yn == Y) cout << Enter the state abbreviation cin >> Find_State for (x=0x<countx++) if (state_abbrx == Find_State) cout << namex << lives in << statex << endl found++ if ( found) cout << Couldnt find anyone living in the state of << Find_State << . << endl else if ( yn == N) cout << Okay, well continue on << endl << endl break while (yn Y yn = N) sum = 0. 0 average = 0. 0 for ( x=0x<countx++) sum = sum + agex average = sum/count cout << endl << endl << The average ag e of your family is << average << years old. << endl << endl cout << The entered data was << endl << endl for ( x=0 x < count x++) cout << namex << lives in << statex << and is << agex << years old. << endl return 0

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.