You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
WHEN A + B > C AND A + C > B AND B + C > A THEN -- 2 zijden moet >= langste zijde zijn
CASE
WHEN A = B AND B = C THEN 'Equilateral' -- 3 zijden gelijk
WHEN A = B OR B = C OR A = C THEN 'Isosceles' -- 2 zijden gelijk
ELSE 'Scalene' -- geen gelijke zijden
END
ELSE 'Not A Triangle'
END
FROM TRIANGLES
/*
Write a query identifying the type of each record in the TRIANGLES table using its three side lengths. Output one of the following statements for each record in the table:
Equilateral: It's a triangle with sides of equal length.
Isosceles: It's a triangle with sides of equal length.
Scalene: It's a triangle with sides of differing lengths.
Not A Triangle: The given values of A, B, and C don't form a triangle.