I am new to nasm and I need to write oprogram that reads (user input) numbers 0-3000 and converts them to roman numbers. So the user inputs a number between 0-3000 and the the program converts it and outputs the corresponding roman number. Please help!!!
annitaz
-5
Light Poster
Recommended Answers
Jump to PostSo have you written the algorithm out on paper, or made any kind of sketch as to the steps you need to perform?
Or did you just dump the whole assignment on the board, along with all the "gimmetehcodez" bumps to similar threads that I'm seeing.
Read the …
Jump to Postyou can check out this site
http://www.novaroma.org/via_romana/numbers.html
there is a converter on the right
it lets you convert between roman and numbers.
ypu can view the source of the page and get the algorithm.
Jump to Postand here is an improved one:
numtoroman proc uses ebx esi numin : DWORD, romout : DWORD LOCAL numlen : DWORD invoke lstrlen, numin mov numlen, eax mov eax, -1 mov ebx, numin mov ecx, 0 mov edx, romout @@: inc eax cmp byte ptr[ebx + eax], …
All 9 Replies
Salem
5,138
Posting Sage
low_coder
26
Junior Poster in Training
annitaz
-5
Light Poster
low_coder
26
Junior Poster in Training
Salem
commented:
Answer on a plate solution, no "help" at all in improving the understanding of the OP
-4
low_coder
26
Junior Poster in Training
annitaz
-5
Light Poster
low_coder
26
Junior Poster in Training
Salem
5,138
Posting Sage
low_coder
26
Junior Poster in Training
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.