COMP 248 Lecture 1: RomanChangeV2.java

60 views1 pages

Document Summary

/* purpose: this program calculates the change to be given by a roman vendor. /* we assume that the client always pays 1 solidus (7200 nummus) and. /* that the item costs between 1 to 7200 nummus. // imports import java. util. scanner; // to be able to read the user input public class romanchangev2 public static void main(string[] args) // main of variables int price; // the price of the item int nbmiliarense = 0, nbsiliqua = 0, nbfollis = 0; // the number of each denomination to return. // setting up scanner for keyboard user input. // step 1: get the price from the user. System. out. print("enter the price of the ticket in nummus (at most. System. out. println("\nyou bought a ticket for " + price + " nummus and gave me a solidus, so your change is");

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents

Related Questions