PRMO level question of functions Consider the functions $f(x)$ and $g(x)$ which are defined as $f(x)=(x+1)(x^2+1)(x^4+1)\ldots\left({x^2}^{2007}+1\right)$ and $g(x)\left({x^2}^{2008}-1\right)= f(x)-1$.
Find $g(2)$
This is a PRMO level question of functions and I tried it with substituting values also but to no avail and the solution Of this question is also not available thought answer is given as $g(x)=2$.

We can write
$$
g\left( x \right) = \frac{{\left( {x + 1} \right)\left( {x^2  + 1} \right) \ldots \left( {x^{2^{2007} }  + 1} \right) - 1}}
{{\left( {x - 1} \right)\left( {x + 1} \right)\left( {x^2  + 1} \right) \ldots \left( {x^{2^{2007} }  + 1} \right)}}$$
and then get
$$
g\left( x \right) = \frac{1}
{{x - 1}} - \frac{1}
{{\left( {x - 1} \right)\left( {x + 1} \right)\left( {x^2  + 1} \right) \ldots \left( {x^{2^{2007} }  + 1} \right)}}$$
So $g(2) = 1-\epsilon$
where $\epsilon=\frac{1}
{{\left( {2 + 1} \right)\left( {2^2  + 1} \right) \ldots \left( {2^{2^{2007} }  + 1} \right)}}=\frac{1}{4^{2008}-1}$.
