Skip to content

Commit

Permalink
Assignment.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
sorandomchad committed Feb 6, 2018
1 parent ac8bb47 commit c6b0da2
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions Assignment.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
#include <iostream>
#include <vector>
#include <string>
#include "Assignment.h"
using namespace std;

int main()
{
int studentNumber;
string studentName;
Assignment student;
vector<Assignment>myVector;

cout << "Enter name and ID number of student (0 to end)
do
{
cin >> studentName;
cin >> studentNumber;
student.setName(studentName);
student.setNumber(studentNumber);
myVector.push_back(student);
}while(studentNumber)
for(int x = 0; x < myVector.size(); x++)
{
cout << myVector[x].getName() << " " << myVector[x].getID() << endl;
}
system("pause");
return 0;
}

0 comments on commit c6b0da2

Please sign in to comment.