Hi! So I was working on the Sals-Shipping project, and I had a quick question for you. I noticed that in my final function to determine which shipping option was the cheapest and print its cost, it was printing “None” after the shipping option and cost. Heres the function I wrote : https://prnt.sc/tp07un and heres what outputs into the console after I print the function with weight as 4.8 : https://prnt.sc/tp08lg . This isnt bothering me that much, its just I wanted to know this was normal and i didnt make a mistake in my code anywhere, thanks for the help !
Heres the link to the project https://www.codecademy.com/courses/learn-python-3/projects/sals-shipping
Hey there @atulahuja8161051768!! Welcome to the codecademy forums
If the picture shows your full function, than the reason
None, is because you don’t have a
In order to use the functions value in that way the function has to return something. For example:
def add(n1, n2): return n1 + n2 print add(5, 5) #prints 10 number = add(3, 3) #number equals 6
Thanks so much!