Skip to content
This repository was archived by the owner on May 13, 2024. It is now read-only.

Latest commit

 

History

History
14 lines (8 loc) · 451 Bytes

File metadata and controls

14 lines (8 loc) · 451 Bytes

Problem 2

Write a java program to return the Fibonacci series up to the value of n, which will be inputted into your method.
* Create one method that completes the task using iteration.
* Create one method that completes the task using recursion.

UNIT TESTING IS MANDATORY !!!

Example:

public String fibonacciIteration(Int n)

Given that n = 150 your output should be “0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144”