-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.cpp
37 lines (31 loc) · 832 Bytes
/
main.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#include <iostream>
#include "Element.h"
#include "StableMatchSet.h"
#include "SetOfElements.h"
using namespace std;
int main(int argc, char** argv) {
ifstream input;
input.open(argv[1]);
if (!input.is_open())
cout << "not open";
SetOfElements setA(input);
cout << "Set A contains: " << endl;
setA.printSet();
input.close();
input.open(argv[2]);
if (!input.is_open())
cout << "not open";
SetOfElements setB(input);
cout << "Set B contains: " << endl;
setB.printSet();
input.close();
StableMatchSet match;
match.determineMatches(setA, setB);
match.printMatches();
cout << "Result of verification function: ";
if (match.matchesAreStable(setA, setB))
cout << "true" << endl;
else
cout << "false" << endl;
return 0;
}