🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← All topics

Quiz: Solving Recurrences: questions with answers

15 questions, each with the answer and a short explanation.

Take the timed quiz + get a certificate →
  1. Q1. For aₙ = 4aₙ₋₁ − 4aₙ₋₂, what form does the general solution take?
  2. Q2. What does this print? (code)
  3. Q3. What are the roots of r³ − 6r² + 11r − 6 = 0?
  4. Q4. For aₙ = 3aₙ₋₁ + 2ⁿ, what should you try as the particular solution?
  5. Q5. For aₙ = 2aₙ₋₁ + 2ⁿ, why does the guess P·2ⁿ fail?
  6. Q6. What is the closed form of aₙ = 2aₙ₋₁ + 2ⁿ with a₀ = 1?
  7. Q7. What does this print? (code)
  8. Q8. Unrolling T(n) = T(n − 1) + n with T(1) = 1 gives:
  9. Q9. Which generating function produces the Fibonacci numbers 0, 1, 1, 2, 3, 5, …?
  10. Q10. You solved a recurrence by hand. What is the quickest reliable check?
  11. Q11. What is the general solution of aₙ = aₙ₋₂ (characteristic roots 1 and −1)?
  12. Q12. For aₙ = 3aₙ₋₁ + 5, what is the constant particular solution P?
  13. Q13. What does this print? (code)
  14. Q14. For aₙ = 2aₙ₋₁ + 3ⁿ, what should you try as the particular solution?
  15. Q15. Which sequence does the generating function 1/(1 − x)² produce?