-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.cpp
35 lines (31 loc) · 1.63 KB
/
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
#include "./headers/Corners.hpp"
#include "./headers/Edges.hpp"
std::string solution(std::string cornerConfigFile, std::string edgeConfigFile){
Corners cornerLattice(cornerConfigFile, "./solved/solvedCorners.txt");
cornerLattice.permute();
std::string cornerString = cornerLattice.solutionString;
Edges edgeLattice(edgeConfigFile, "./solved/solvedEdges.txt");
edgeLattice.permute();
std::string edgeString = edgeLattice.solutionString;
return cornerString + "\n\n" + edgeString;
}
int main(void){
std::cout << "Solution for test #1:\n"
<< "----------------------\n\n";
std::cout << solution("./tests/test01/corners.txt", "./tests/test01/edges.txt") << "\n";
std::cout << "Solution for test #2:\n"
<< "----------------------\n\n";
std::cout << solution("./tests/test02/corners.txt", "./tests/test02/edges.txt") << "\n";
std::cout << "Solution for test #3:\n"
<< "----------------------\n\n";
std::cout << solution("./tests/test03/corners.txt", "./tests/test03/edges.txt") << "\n";
std::cout << "Solution for test #4:\n"
<< "----------------------\n\n";
std::cout << solution("./tests/test04/corners.txt", "./tests/test04/edges.txt") << "\n";
std::cout << "Solution for test #5:\n"
<< "----------------------\n\n";
std::cout << solution("./tests/test05/corners.txt", "./tests/test05/edges.txt") << "\n";
std::cout << "Solution for test #6:\n"
<< "----------------------\n\n";
std::cout << solution("./tests/test06/corners.txt", "./tests/test06/edges.txt") << "\n";
}