6. Income on the Nth day #

Created Sunday 02 August 2020

F(n) = F(n-1)+F(n-2)+F(n-1)*F(n-2)

Uses all 4:

  1. Matrix Exponentiation
  2. Modular Exponentiation
  3. Fermat’s Little theorem
  4. Recurrence Relations