#PCBBAY0000014. In số thực với hai chữ số thập phân (Print Two Decimal Places)
In số thực với hai chữ số thập phân (Print Two Decimal Places)
Print Two Decimal Places
Version: Phuoc Hung OJ Extended
Problem Statement
Given a real number , display it in fixed-point notation with exactly 2 digits after the decimal point. Pad with trailing zeros when necessary; otherwise use Python 3 float formatting. Preserve a negative sign if it appears in the formatted value.
Input
One line contains real .
Output
Print using .2f, including trailing zeros and any negative sign.
Subtasks
- Subtask 1 (100 points): .
Examples
Example 1
Input
12.5
Output
12.50
Explanation. For input 12.5, applying .2f formatting produces exactly 12.50 (including any trailing zeros, separators or exponent characters).
Example 2
Input
3.14159
Output
3.14
Explanation. For input 3.14159, applying .2f formatting produces exactly 3.14 (including any trailing zeros, separators or exponent characters).
Example 3
Input
-0.004
Output
-0.00
Explanation. For input -0.004, applying .2f formatting produces exactly -0.00 (including any trailing zeros, separators or exponent characters).