Showing posts with label Shipping Cost Solver in Python. Show all posts
Showing posts with label Shipping Cost Solver in Python. Show all posts

Friday, March 15, 2019

Shipping Cost Solver in Python

Write a program that will ask the user the county of origin of the shipment of the package and it's weight in kilograms and then the program will compute its shipping cost by the sender and the display the result on the screen using nested if statement.


Program Listing

# Rollyn M. Moises and Jake R. Pomperada
# shipping.py
# February 7, 2019  Thursday
# Bacolod City, Negros Occidental
print();
print("\tShipping Cost Solver");
print();
country = input("\tWhat country : ");
weight = int(input("\tWeight in Kilogram(s) :"));
print();

if country == "japan":
    if weight <= 50:
        print("\tShipping Cost is  $250");
elif weight >= 100:
        print("\tShipping Cost is $375");
elif weight <= 20:
   print("\tShipping Costs $100");
if country == "thailand":
if weight >= 50:
         print("\tShipping Cost is  $100");
else:
    print("\tFREE");
print();
print("\tEND OF PROGRAM");