Preparing For IMO
CodeChefOpen on judge ↗
Harshit was preparing for International Maths Olympiad and came across a problem. The following function $f(x)$ was given and he had to calculate its value for a given $x$. $\scriptsize f(x)=\left\{\begin{matrix} \hspace{25pt} 1 \hspace{200pt} ; x=0 \\ 1 + \sum_{i=0}^{n} \left (-\frac{7}{26}\sqrt{13}\left ( \frac{3}{2}-\frac{\sqrt{13}}{2} \right )^i + \frac{7}{26}\sqrt{13}\left ( \frac{3}{2}+\f
HINT LADDERno hints yet
L1 Observation
L2 Technique
L3 Approach
L4 Pseudo-code
🔒
L5 Full solution
L5 unlocks only if you insist twice
solution.cppC++17
CodeSearch Tutor
Hints, not spoilers — it won’t hand over the full solution unless you insist.
Sign in to chat with the tutor and save your progress.
Sign in to start