Suppose that you have a variable that holds a monetary value in cents. Write statements in Java that will compute the number of $1000 , $1 and 1 cent needed to compose the amount.
Attempt :
we take a random number ( 43,567 ) and assign it to int cents ?
$1000 x 43567 = 43 times ( 40,000) ?
i am not sure how to go about it, any help will be appreciate .