.each/.collect


#1


This is just experimentation, but why does this not work? It returns the same numbers that I started with in the array.
I tried this as I dont see the difference between .collect and .each

fibs = [1, 1, 2, 3, 5, 8, 13, 21, 34, 55]

# Add your code below!
fibs.each do |fib|
    fib ** 2 
    puts fib
    end


#2

The above line is not doing anything (except in a vacuum). Combine it with the puts statement...

puts fib ** 2

#3

Cheers. And can someone explain the difference between .each and .collect to me pls?