Skip to content

Latest commit

 

History

History
6 lines (5 loc) · 275 Bytes

File metadata and controls

6 lines (5 loc) · 275 Bytes

Write a function series(n: int) → float that returns the nth term of a sequence defined by a_i = 3√(a_(i-1)) where a_0 = 1. Return the final result rounded to 3 decimal places.

For example:

  • series(1) → 3.0
  • series(3) → 6.839
  • series(4) → 7.845