popovIliya

March-2022-FirstStepsInCoding-Exercise-Soft Uni - Basketball Equipment

Mar 5th, 2022
1,205
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function costs(input){
  2.  let anAnnualFee = Number(input[0]);
  3.  let priceSneakers = anAnnualFee - (anAnnualFee * 0.40);
  4.  let priceClothing = priceSneakers - (priceSneakers * 0.20);  
  5.  let priceBall = (1 / 4) * priceClothing;
  6.  let priceAccessories = (1 / 5) * priceBall ;
  7.  let payments = anAnnualFee + priceSneakers + priceClothing + priceBall + priceAccessories;
  8.  console.log(payments);
  9. }
Advertisement
Add Comment
Please, Sign In to add comment