LOJ # 2106. "JLOI2015" meaningful string structure + matrix multiplication

This question is the true test of a person's perception of mathematics ah .....

See $ \ frac {b- \ sqrt d} {2} $ necessary to form a think this is one of a root of a quadratic equation, and then to the solution.  

Think of this step, then do just fine, because we can be listed on a $ n $ is recursive, then matrix multiplication can be accelerated. 

The code is not posted .... 

Guess you like

Origin www.cnblogs.com/guangheli/p/12459924.html