Advertisement
Spocoman

Easter Lunch

Feb 13th, 2022
52
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. function easterLunch(input) {
  2.     let easterBread = parseInt(input[0]);
  3.     let eggPack = parseInt(input[1]);
  4.     let cookies = parseInt(input[2]);
  5.  
  6.     let sum = easterBread * 3.2 + eggPack * 4.35 + cookies * 5.4 + eggPack * 0.15 * 12;
  7.  
  8.     console.log(sum.toFixed(2))
  9. }
  10.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement