P6353 [COCI 2007/2008 #3] OKTALNI

Description

You are given a binary number. Please convert it to an octal number. --- You can use the following conversion method: - If the number of bits in the binary number is not divisible by $3$, pad $0$ on the left until the length becomes a multiple of $3$. - Split this binary number into groups of three bits. - The binary value of each group can be replaced by the digit shown in the table below. ![](https://cdn.luogu.com.cn/upload/image_hosting/tcwf1oqm.png) Now complete this procedure and output the final octal result.

Input Format

Input one line containing a binary number. It is guaranteed that the length does not exceed $100$, and the first bit is $1$.

Output Format

Output one line containing an octal number.

Explanation/Hint

#### Note **This problem is translated from [COCI2007-2008](https://hsin.hr/coci/archive/2007_2008/) [CONTEST #3](https://hsin.hr/coci/archive/2007_2008/contest3_tasks.pdf) *T2 OKTALNI***。 Translated by ChatGPT 5