← Problem book: Python
Lesson 25 of 96 · 10 XP
Absolute value
Theory and problem statement
Machine translation, not yet reviewed by a native speaker.
You are given an integer. Print its absolute value without using the built-in abs function.
Example
Input:
-5
Output:
5
Sign up for free to solve this task right in your browser: code editor, running, test checks and hints.