Conditional operator




Task
Time limit: 1000 ms,
Memory limit: 256 Mb

Given a non-zero integer. Display its absolute value on the screen (conditionally assuming that there is no corresponding standard function). Do not use the full conditional statement.

In the program it is forbidden to use the words: abs, else
Prohibited statements:abs; else

Auto CHOOSE THE PROGRAMMING NECESSARY LANGUAGE!
Attach the program source file:
or enter the source code in the language:

Rules for designing programs and a list of errors during automatic task verification
           

Results: