Given the lengths of a lever's left and right arms, determine whether it is balanced, tips left, or tips right.
Problem
You are given two positive integers representing the lengths of the left and right arms of a lever.
A lever is:
- balanced if the two arms have the same length,
- left-heavy if the left arm is longer,
- right-heavy if the right arm is longer.
Print the appropriate result based on the comparison.
Task
Read the two lengths and output the direction in which the lever would tilt, or that it is balanced.
Input Format
- A single line contains two integers and — the lengths of the left and right arms.
Output Format
- Print
Balancedif . - Print
Leftif . - Print
Rightif .
Constraints
Example 1
Input
5 5
Output
Balanced
Explanation
Both arms have the same length, so the lever is balanced.
Example 2
Input
7 3
Output
Left
Explanation
The left arm is longer, so the lever tilts left.
Show 1 more example
Example 3
Input
2 9
Output
Right
Explanation
The right arm is longer, so the lever tilts right.
Premium problem context
Unlock deeper context for this problem
Premium adds guided hints, editorial links, similar variants, discussion resources, and concept maps so you can understand why a problem matters, not just solve it once.