CJCoding With Joseph
15free / daySign inCreate account

Can It Be A Triangle

Read three side lengths and decide whether they can form a triangle: they can only when the sum of every pair of sides is greater than the third side. Print Valid triangle or Not a triangle. Input: three lines, each a positive integer, no prompts. Output: one line. Join the three comparisons with and.

Expected Output:

Valid triangle

= newline. The output ends with a newline — print one after the last line.

Hints3 available
Topics:
If StatementsOperators
📥 Auto-Input:
3\n4\n5\n
This input is automatically fed to your program's stdin
1
Tab to indent (Esc then Tab to move on) · Ctrl+Enter to run · Ctrl+Space to expand shortcuts (pr, inp, def)

Your Output

Run your code to see the output here...

Test Cases

Run your code to see test case results.