A fraction written in octal (base 8) can always be written exactly in decimal (base 10). For example, the octal number 0.75 equals $7/8 + 5/64 = 0.953125$ in decimal. Every octal fraction with $n$ digits after the point can be written with at most $3n$ digits after the decimal point.
Write a program that converts octal fractions strictly between 0 and 1 into the equivalent decimal fractions.
The input is a list of octal numbers to convert, one per line. Each number has the form $0.d_1 d_2 d_3 \dots d_k$, where every $d_i$ is an octal digit ($0$ through $7$). There is no limit on the number of digits $k$. Input continues until end of file.
For each input line, print one line of the form
X [8] = 0.Y [10]
where $X$ is the input octal number copied verbatim and $0.Y$ is its decimal value. On the decimal side, strip every trailing zero so the last digit is never $0$.