?#12


#1

What is me supposed to do here???:

odds = [1,3,5,7,9]

# Add your code below!

and it sez to do this:

Use the .each method on the odds array to
 print out double the value of
 each item of the array. In other words, multiply each
 item by 2.

Pleeez anser. Tank youz!


#2

Please post the code that you tried (which isn't also working) along with the line where you are doubtful or not able to understand instructions. The instructions seem clear to me.


#3

I don't get it. That's why I don't have a code.


#4

The syntax for .each operator is:

array.each do |name_for_one_element|
    # do stuff
end

Here your name_for_one_element can be anything you want, it would represent each element in the array you are iterating over.
And you have to print double the value of each element, so do that in the #do stuff line.

Hope it helps! :slightly_smiling: