-
Notifications
You must be signed in to change notification settings - Fork 0
/
1045.py
51 lines (44 loc) · 988 Bytes
/
1045.py
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#include<stdio.h>
n = input().split()
n1, n2, n3 = float(n[0]), float(n[1]), float(n[2])
a = n1
b = n2
c = n3
if n1 >= n2 and n1 >= n3:
a = n1
if n2 >= n3:
b = n2
c = n3
else:
b = n3
c = n2
if n2 >= n1 and n2 >= n3:
a = n2
if n1 > n3:
b = n1
c = n3
else:
b = n3
c = n1
if n3 >= n1 and n3 >= n2:
a = n3
if n1 >= n2:
b = n1
c = n2
else:
b = n2
c = n1
if a >= (b + c):
print('NAO FORMA TRIANGULO')
else:
if (a ** 2) == ((b ** 2) + (c ** 2)):
print('TRIANGULO RETANGULO')
if (a ** 2) > ((b ** 2) + (c ** 2)):
print('TRIANGULO OBTUSANGULO')
if (a ** 2) < ((b ** 2) + (c ** 2)):
print('TRIANGULO ACUTANGULO')
if a == b and b == c:
print('TRIANGULO EQUILATERO')
else:
if a == b or b == c or a == c:
print('TRIANGULO ISOSCELES')