7/14 Help


#1

I have a issue with the number 7. Can you guys please help me to solve it.
Thank you


#2

Hey.

Please post your code so we can review it and help you.

We are not just going to tell you the answer as that wouldn't help you understand it :wink:


#3

You are right.

my_list = [1,9,3,8,5,7]

for number in my_list:
# Your code here
number = my_list(:smile:
print 2 * number


#4

my_list = [1,9,3,8,5,7]

for number in my_list:
# Your code here
number = my_list( : )
print 2 * number


#5

Hey.

You don't need to asign the number = my_list(:) variable as we already assigned it in the for loop.

Your code should end up being:

my_list = [1,9,3,8,5,7]

for number in my_list:
    print number * 2

P.S. - Please use code tags in the future as it really helps people fix your issue :smile:


#6

Thank you so much.
I will next time.


#7

You're welcome :smile:

Please feel free to use the new like feature on the forum as it helps find the solution to the same problem you had easier :smile: