-->
当前位置:首页 > 题库

PROGRAMMING:The secret of ZF series

Luz5年前 (2021-05-10)题库437
After getting the magic sword firefly, ZF always felt uneasy. The villagers suggested to go to the big wizard ⊙ - ⊙ Levi for advice. However, to ask the big wizard for advice, we need to solve the big wizard's problems,
Smart acmers, can you do it?
Levi discovered the magic binary number while watching the stars.
If a positive integer m is expressed as binary, its number of digits is n (excluding leading 0), ⊙ - ⊙ Levi calls it an N binary number. In all N binary numbers, the total number of 1 is called the corresponding number of n.
For example, there are four binary numbers of 3, which are 4 (100), 5 (101), 6 (110) and 7 (111). Among them, the number of 1 is 1 + 2 + 2 + 3 = 8, so the corresponding number of 3 is 8.
Input n and output their corresponding number of secrets. Only when we find the secret of the number of secrets can we solve the haze and the mystery~
There is a period of prosperity and weakness, and there is a number of natural opportunities. ~ by: ⊙ - ⊙ Levi
###Input format:
A number n (n < 25)
###Output format:
The corresponding number of days
###Input example:
Here is a set of inputs. For example:
```in
one
two
three
```
###Output example:
The corresponding output is given here. For example:
```out
one
three
eight
```







answer:If there is no answer, please comment