Question: Add elements to your roman.html page so that the user can perform the opposite conversion, translating a number into an ancient Roman numeral. [One approach

Add elements to your roman.html page so that the user can perform the opposite conversion, translating a number into an ancient Roman numeral.

[One approach to building the Roman numeral would be to write a series of while loops. As long as the number entered by the user is greater than or equal to 1,000, add the letter "M" to a string representing the Roman numeral and subtract 1,000 from the value. If the resulting number is greater than or equal to 500, add "D" to the string and subtract 500. Then, repeatedly add "C"s and subtract 100 until the number becomes less than 100, and so on.]

Step by Step Solution

3.37 Rating (163 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Document Format (1 attachment)

Word file Icon

1409-C-S-O-S(1130).docx

120 KBs Word File

Students Have Also Explored These Related Operating System Questions!