None after the code and how i get not a none after the code is printed

i get after i execute the code a none after the print statement
so my question is how i dont get the none after the print statement

def ground_shipping(weight):

if weight <= 2 :

price =  1.50

elif weight <= 6 :

 price = 3.00

elif weight <= 10 :

price =  4.00

elif weight > 10 :

price =  4.75

return weight * price + 20.00

flat_charge = 125.00

def drone_shipping(weight):

if weight <= 2 :

price = 4.50 

elif weight <= 6 :

price = 9.00

elif weight <= 10 :

price = 12.00

elif weight > 10 :

price = 14.25

return weight * price

def cheap_shipping(weight):

premium = flat_charge

ground = ground_shipping(weight)

drone = drone_shipping(weight)

if premium < drone and premium < ground:

print("Premium Ground Shipping is the cheapest method! your weight of " + str(weight) + "lb will cost total 125 dollar"   )

elif drone < premium and drone < ground:

print(“Drone shipping is the cheapest method! your weight of” +str(weight)+ “lb will cost “+ str(drone)+” Dollar”)

elif ground < premium and ground < drone:

print("Ground Shipping is the cheapest method! your weight of " + str(weight) + “lb will cost " + str(ground) + " Dollar”)

else:

return

print(cheap_shipping(4.8))

print (cheap_shipping(41.5))

Since the cheapest_shipping function is printing the outcome, we don’t need to print the function call. There is no return value to print, hence, None.

3 Likes