A logic gate manufacturing company have received a gate input in an encoded form. This encoded form of the gate input is a decimal number. Since the gate accepts only binary inputs the company need to decode the input by converting it to binary form and then pass it through the gate.
20 - 21
22 23
{
// Write
return 0;
}
Write an algorithm to decode the gate input.
Input
The input consist of an integer-gatelnput representing the encoded gate input.
Output
Print an integer consisting of only Os and 1s that represents the decoded gate input.
Constraints
0
Example
123
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here