Write a class with an internal iterator that can be used to print out the Fibona
ID: 3640733 • Letter: W
Question
Write a class with an internal iterator that can be used to print out the Fibonacci sequence, starting from Fibonacci number 0, which is 0 and Fibonacci number 1, which is 1, then each next number being the sum of the previous two (#2 is 1, #3 is 2, #4 is 3, #5 is 5, etc.). The constructor for your class should have an int parameter that specifies the maximum Fibonacci number. In your inner class, the remove() method should just throw an UnsupportedOperationException.Test your class with a driver program that will prompt for and input an integer, instantiate a Fibonacci object with that integer as the maximum Fibonacci number, and print out all of the Fibonacci numbers up to that number, using an enhanced for loop.
The code must be completed how i asked to get full points. The code must include a comment for each method describing the method, a comment for each parameter describing what the parameter represents, and a comment for each variable declaration (including instance variables) describing what the variable represents.