407179: GYM102697 150 Valid Triangle
Memory Limit:256 MB
Time Limit:1 S
Judge Style:Text Compare
Creator:
Submit:0
Solved:0
Description
150. Valid Triangletime limit per test1 secondmemory limit per test256 megabytesinputstandard inputoutputstandard output
Your task for this problem is to take the three side lengths of a triangle and to determine if these side lengths could create a "valid" triangle. A triangle is considered valid if the addition of any two side lengths is less than the length of the other side, in other words, the following must evaluate to true: a+b>c, a+c>b, b+c>a.
InputThe first line contains three space separated integers that correspond to the lengths of sides a, b, and c respectively.
OutputOutput either "VALID" or "INVALID" depending on if the provided side lengths create a valid or invalid triangle.
ExamplesInput1 5 1Output
INVALIDInput
4 5 6Output
VALID