A store had 100 t-shirts. each month, 30% of the t-shirts were sold and 25 new t-shirts arrived in shipments. which recursive function best represents the number of t-shirts in the store, given that f(0) = 100? (1 point) f(n) = f(n − 1) ⋅ 0.3 + 25, n > 0 f(n) = 100 − f(n − 1) ⋅ 0.3 + 25, n > 0 f(n) = f(n − 1) ⋅ 0.7 + 25, n > 0 f(n) = 100 − f(n − 1) ⋅ 0.7 + 25, n > 0
Question
Answer:
f(n) = f(n â’ 1) â‹… 0.7 + 25, n > 0 Well, let's create a recursive function and see what option best matches it. Since our initial inventory is 100, we'll define f(0) as 100.
For month n, we sell 30% of the t-shirts. So we have f(n-1)*(1-0.3) = f(n-1)*0.7
And we get 25 more shirts. So f(n-1)*0.7 + 25
Therefore the function is
f(n) = f(n-1)*0.7 + 25, n>0
Which matches the 3rd option given.
The key thing to remember is if we sell 30% each month, that means that we retain 100% - 30% = 70% each month.
solved
general
11 months ago
4014