#include <stdio.h>
#include <math.h>
#include <conio.h>
#include <string.h>
#include <iostream>
#include <cstdlib>
using namespace std;
#include <math.h>
class Triangle {
public:
float st1, st2, st3;
int proverka()
{
if (st1 == st2 && st1 == st3) cout << "Ravn" << endl;
if (st1 == st2 || st1 == st3 || st2 == st1) cout << "Ravnobedr" << endl;
if (st1 == sqrt(st2*st2 + st3 * st3) || st2 == sqrt(st1*st1 + st3 * st3) || st3 == sqrt(st2*st2 + st1 * st1)) cout << "Pramaugolnie" << endl;
else cout << "Треугольник обычный" << endl;
return 0;
system("pause");
}
int calculate() {
float x1, x2, x3, y1, y2, y3;
float S, P;
float st1, st2, st3;
cout << "koordinata 1: "; cin >> x1 >> y1;
cout << "koordinata 2: "; cin >> x2 >> y2;
cout << "koordinata 3: "; cin >> x3 >> y3;
float a, b, c, d, e, f;
a = x2 - x1;
b = y2 - y1;
c = x2 - x3;
d = y2 - y3;
e = x3 - x1;
f = y3 - y1;
st1 = sqrt(((a)*(a)) + ((b)*(b)));
st2 = sqrt(((c)*(c)) + ((d)*(d)));
st3 = sqrt(((e)*(e)) + ((f)*(f)));
P = st1 + st2 + st3;
cout << "Perimetr= " << P << endl << "st1 " << st1 << "st2 " << st2 << "st 3" << st3;
return 0;
system("pause");
}
};
int main(){
Triangle t1;
t1.calculate();
t1.proverka();
return 0;
system("pause");
}