I am using the textbook Mathematical Structures for Computer Science - A Modern Approach to Discrete Mathematics (6e) by Judith L. Gersting.

I don't understand what is going on at all in any of the section 2.4s examples. If someone could explain how the book arrives at the following answers for these questions, I would be very appreciative.

:

Write the first five values in the sequence

1. S(1) = 10

S(n) = S(n-1) + 10 for n >= 2

The books answer is: 10, 20, 30, 40, 50

7. M(1) = 2

M(2) = 2

M(n) = 2M(n - 1) + M(n - 2) for n >= 2

The books answer is: 2, 2, 6, 14, 34