Who can make me the favor of helping me with this "perform a algorithm that allows to identify the type of triangle according to | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Who can make me the favor of helping me with this "perform a algorithm that allows to identify the type of triangle according to

In a loop with "for" and "up"

11th Feb 2020, 8:58 PM
Paula Andrea González
Paula Andrea González - avatar
9 Answers
+ 5
Can you show us your attempt?
11th Feb 2020, 9:12 PM
Aymane Boukrouh
Aymane Boukrouh - avatar
+ 1
You should then, try to solve it yourself first, we're only here to help. Also, there is no "up" loop, only a "for" loop. A triangle only has three measurements, why use a loop at all? Share more details if you got ant. How is the input taken, what should the output look like...
11th Feb 2020, 9:24 PM
Aymane Boukrouh
Aymane Boukrouh - avatar
0
I have not done it, it's a job of a logarithm with a loop but I do not understand how it is done, you know?
11th Feb 2020, 9:22 PM
Paula Andrea González
Paula Andrea González - avatar
0
Thanks
11th Feb 2020, 9:37 PM
Paula Andrea González
Paula Andrea González - avatar
0
what type odmf triangle?
11th Feb 2020, 9:41 PM
Oma Falk
Oma Falk - avatar
0
i have to identify the type of triangle according to your measures
11th Feb 2020, 10:30 PM
Paula Andrea González
Paula Andrea González - avatar
0
Side measures or angle measures? By type of triangle, do you mean scalene/isosceles/equilateral or do you mean acute/right/obtuse? If you have side measures and you want to know whether the triangle’s largest angle is acute, right, or obtuse, let a,b be the two shorter side lengths and let c be the longer. Then check whether a^2+b^2 is greater than, equal to, or less than c^2.
11th Feb 2020, 11:03 PM
Travis
Travis - avatar
0
they explained it to me like this way in Spanish 1.Inicio 2. Leer (L1, L2, L3) 3. Escribir “Ingrese los 3 L (Lados)” 4.Si (L1<>L2 y L1<>L3) Entonces 5.Escribir “Es un equilátero” Sino 6.Si (L1<>A o L2<>L3 o L3<>L2) Entonces 7.Escribir “Es un isósceles” Sino 8.Escribir “Es un escaleno” FinSi Finsi 9.Fin
11th Feb 2020, 11:41 PM
Paula Andrea González
Paula Andrea González - avatar
0
You could try something like: L=[L1,L2,L3] T=[] for i in range(3): T+=[ L[i]==L[(i+1)%3] ] e=sum(T) Then have different cases for e=0,1, and 3. I am not sure what you mean by using “up,” but at least this gets you a for loop.
11th Feb 2020, 11:58 PM
Travis
Travis - avatar