Advertisement
182days

(0478) 2016 Pre Task 1

Apr 25th, 2016
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.66 KB | None | 0 0
  1. #input checker
  2. x = int(input("Enter the width of the parcel..."))
  3. y = int(input("Enter the length of the parcel..."))
  4. z = int(input("Enter the depth of the parcel..."))
  5. w = int(input("Enter the weight of the parcel..."))
  6. d = x + y + z
  7. if x <=80 and y <=80 and z <=80 and d <=200 and w >=1 and w <=10:
  8.     print("Parcel Accepted!")
  9. else:
  10.     print("Parcel rejected due to...")
  11.     if x >80:
  12.         print("Width too big")
  13.     if y >80:
  14.         print("Length too big")
  15.     if z >80:
  16.         print("Depth too big")
  17.     if d >200:
  18.         print("Dimensions too big")
  19.     if w <1:
  20.         print("Weight too light")
  21.     if w >10:
  22.         print("Weight too heavy")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement