blob: 217b95e67921a1fa3f052c0159e5e5989fb3528d (
plain)
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
|
#include <iostream>
#include <vector>
#include "../include/point.hpp"
#include "../include/triangle.hpp"
using namespace std;
int main(int argc, char* argv[]) {
(void)argc;
(void)argv;
Point p1(1,1);
Point p2(0,0);
Point p3(2,0);
Triangle t1(p1, p2, p3);
cout << "Perimeter of triangle [" << p1.str() << ", " << p2.str() << ", " <<
p3.str() << "] = " << t1.perimeter() << endl;
if(p3 > p1) {
cout << "p1 is smaller than p2" << endl;
}
return 0;
}
|