Solution
Challenges » Solution
Author: Edward H File Size: No size given |
The string "IVXLCDMvxlcdmni" specifies the letters used in the numerals. The longer you make the string, the more digits the program can handle. To satisfy the program requirements, the string must have at least as many characters as "IVXLCDMvx"; everything else is extra digit support. |
Want to update this page?
You can edit the content of this page to provide up-to-date information about your program, or even update your program (provided the challenge is not yet finished).
What the community thinks:
Hello,
Nice program, it works well and I like it :) .
I don't know if you use Prompt for space-saving (the program is only 140 ) but I would use Input "Number?",N to make it some more userfriendly.
I also have put in a check for N, if N is bigger than 3999 the program starts using the wrong tokens (4000=Mv).
And, I don't know if this is just the engine, but of course some more things can be done to make it more userfriendly. Like a ClrHome in the beginning of the program or a Disp "Roman number=" at the end.
I like the program very much, thanks for making :D
HJTP
It uses prompt, yeah. Click "Show Code" to see it all.
Also, not clearing the screen isn't a problem in my mind, because then you can see multiple results at once.
/Socks
Mv is exactly the way I intend to display 4000. I use lowercase letters as an extension of the Roman Numeral system.
v = 5,000
x = 10,000
l = 50,000
c = 100,000
d = 500,000
m = 1,000,000
n = 5,000,000
i = 10,000,000
And you could extend that even more by adding more digits to the string. Looking back, it's a pretty slick bit of code.
COOL!!!
I've seen Ostermiller put up a version on his site, but it won't go over 3999. This one is much smaller, too.
COOL!!!