Loading iterators/iterators.go +0 −6 Original line number Diff line number Diff line Loading @@ -25,12 +25,6 @@ func (fn *FibonacciNumber) Value() *big.Int { // Next ... func (fn *FibonacciNumber) Next() *big.Int { //r := f.current //n := big.NewInt(0) //n.Add(f.next, f.current) //f.current = f.next //f.next = n fn.current, fn.next = fn.next, fn.current.Add(fn.next, fn.current) return fn.current Loading Loading
iterators/iterators.go +0 −6 Original line number Diff line number Diff line Loading @@ -25,12 +25,6 @@ func (fn *FibonacciNumber) Value() *big.Int { // Next ... func (fn *FibonacciNumber) Next() *big.Int { //r := f.current //n := big.NewInt(0) //n.Add(f.next, f.current) //f.current = f.next //f.next = n fn.current, fn.next = fn.next, fn.current.Add(fn.next, fn.current) return fn.current Loading