Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- }
- function parseDonuts(donutString) {
- numDonuts = parseInt(donutString); //Verifica se a palavra duzia aparece nos dados digitados
- if (donutString.indexOf("dozen") != -1)
- numDonuts *= 12; //Mutiplica o numero por 12
- return numDonuts;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement