[Solved] JavaScript program to make change

30 $

File Name: JavaScript_program_to_make_change.zip
File Size: 310.86 KB

SKU: [Solved] JavaScript program to make change Category: Tag:

Or Upload Your Assignment Here:


Write a JavaScript program to make change. You should use prompt() to read a string and parseInt() to convert the string into an integer number of cents (i.e. fractions of a dollar). Your program should write to the document how to deliver that number of cents as change using a minimum number of US coins as output. Ignore the 50 cent piece as a possible coin. So for example, given an input of 87, your program should output the following to the document:87 cents is comprised of:3 quarter(s)1 dime(s)0 nickle(s)2 penniesHint: Remainders from division are calculated with the modulus operator.

Reviews

There are no reviews yet.

Only logged in customers who have purchased this product may leave a review.

Shopping Cart
[Solved] JavaScript program to make change
30 $