Heximal

아직 제출이 없습니다시간 제한5초메모리 제한1024 MB

문제

The base-6 numeral system is also called the heximal numeral system. We say a string h_kh_k1h_1h_0h\_kh\_{k-1} \cdots h\_1h\_0 is a heximal number if h_i0,1,2,3,4,5h\_i ∈ \\{0, 1, 2, 3, 4, 5\\} for every i0,1,,ki ∈ \\{0, 1, \dots , k\\} and h_k=0h\_k = 0 implies k=0k = 0. The value represented by h_kh_k1h_1h_0h\_kh\_{k-1} \cdots h\_1h\_0 in the heximal numeral system is k_i=0h_i6i\sum^{k}\_{i=0}{h\_i6^i}. For example, the value of the heximal number 1234512345 equals the value of the decimal number 1865=1×64+2×63+3×62+4×6+51865 = 1 × 6^4 + 2 × 6^3 + 3 × 6^2 + 4 × 6 + 5.

Harry asks you to convert a very large base-10 number NN to base-6. Since the conversion result can be very long, it is too hard for Harry to verify the result by himself. So, you just need to tell Harry the length of the conversion result. For example, if N=1865N = 1865, then you just need to tell Harry the length of the conversion result is 55.

입력

The input contains exactly one integer NN in decimal.

출력

Output the length of the base-6 representation of NN.

제한

  • 0N<105000000 ≤ N < 10^{500000}.