#CCBCMCHIN0000037. Else gắn với if gần nhất (Dangling Else)
Else gắn với if gần nhất (Dangling Else)
Dangling Else
Source: Phước Hưng OJ
Version: Phuoc Hung OJ Extended
Problem Statement
Initialize . Set if and ; set if and ; otherwise retain . Print .
Input
A line contains two integers .
Output
Print the integer determined by the stated rules.
Subtasks
Subtask 1 (20 points): Both integers have absolute value at most 2. Subtask 2 (30 points): Both integers have absolute value at most 100. Subtask 3 (50 points): Both integers have absolute value at most 10^9.
Examples
Example 1
Input
3 -2
Output
2
Explanation
Since x > 0 but y > 0 is false, the inner else sets z to 2.
Example 2
Input
-1 -2
Output
0
Explanation
Since x > 0 is false, the outer block does not run; z remains 0.