DiYane

Fruit market - EX

Aug 3rd, 2021 (edited)
187
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.58 KB | None | 0 0
  1. strowberry_price = float(input())
  2. bananas_kg = float(input())
  3. oranges_kg = float(input())
  4. raspberry_kg = float(input())
  5. strowberry_kg = float(input())
  6.  
  7. raspberry_price = strowberry_price / 2
  8. oranges_price = raspberry_price - (raspberry_price * 0.40)
  9. bananas_price = raspberry_price - (raspberry_price * 0.80)
  10.  
  11. raspberry_sum = raspberry_price * raspberry_kg
  12. oranges_sum = oranges_kg * oranges_price
  13. bananas_sum = bananas_kg * bananas_price
  14. strowberry_sum = strowberry_kg * strowberry_price
  15.  
  16. money_needed = strowberry_sum + raspberry_sum + oranges_sum + bananas_sum
  17. print(money_needed)
Advertisement
Add Comment
Please, Sign In to add comment