Sequence#8702

Sequence

1 second
64 megabytes
Easy

Any natural number can be uniquely expressed as a sum of distinct Fibonacci numbers—this is the foundation of the Fibonacci numeral system.

1,\, 10,\, 100,\, 101,\, 1000,\, 1001,\, 1010,\, 10000,\, 10001,\, 10010,\, 10100,\, 10101,\, \ldots

Find the -th term in the following sequence of numbers:

Input

A natural number (1 \le N \le 10^9).

Output

Output the -th term in the sequence.

Examples

Example 1

Loading
Loading