| # | Problem | Pass Rate (passed user / total user) |
|---|---|---|
| 12894 | Decimal Numbers to Binary Numbers |
|
| 12895 | Palindrome Number |
|
Description
給定一個十進位的整數,請試著將他轉成二進位的數
舉例:
- 如果給定的數是21,則轉成二進位的結果為10101
- 如果給定的數是121,則轉成二進位的結果為1111001
Input
一個整數Decimal-Num
Note:
- 32767 >= Decimal-Num >= 0
Output
輸出比須符合以下格式:
Binary-Num
Note:
- 輸出的最後必須要有一個換行符號 ('\n')
- 不需要印出額外的’0’
E.g. 8 => (O) 100 (X) 0000100
Sample Input Download
Sample Output Download
Tags
Discuss
Description
If a number is a palindrome number, that means the that number remains the same value when its digits are reversed.
E.g. 12345 is not a palindrome number because 12345 is not equal to 54321; on the contrary, 10301 is a palindrome number because it remains 10301 when its digits are reversed.
Given an integer. Please Write a C program to tell if it’s a palindrome number.
Input
One integer Num. Note that 32,767 >= Num >= 0.
Output
Output should follow below format:
Yes/No
Note that:
- Need to have a return value('\n') at the end of your string.