I need a c++ program to convert Number to word form.?
-
Write a function that will convert a 5-digit (positive) number into word form. Eg: 123, the output should be one hundred and twenty three... (this should be a c++ program).
-
Answer:
Very well, you need a program. What is your question? Do you want smbdy to do your homework for you? > This is not my homework... > This is the program i have to take for my seminar... Oh, that makes a big difference, lol! > i can't sit in front of my pc for long n work on this coz i have a lots of headache... What about programming books? Can you read them? Can you write? This program is not large, you can always try to write it on paper - then you'll need just to type it, compile and run, it'll not take you much time. If you get any errors, write'em down, return back to your papers and analyze your code. Actually, that was the way programmers work in times "when computers were big" - this is not very quick way, but it helps to improve your programming much.
Praneeth at Yahoo! Answers Visit the source
Other answers
I can't give you the code, but here is how you do it. First separate the digits: by taking the modulus(%) of the nuber by ten eg. no%10, do this in a loop. Get the answer in another variable t[4]; and subtract it from the main number ie. no=no-t[i]; I is the counter that increments with every loop; In a charater variable sent[100]; Start with t[3]; and t[2] put it as as cout<<t[3]*10+t[2] "thousand", print it. go on like this till you come to 0; Hope you can understand and this helps
venkat_the_great
Do your own homework. But you can ask for help on a specific problem here: http://cboard.cprogramming.com/
Answer Master
Related Q & A:
- How to run an executable from within a c program?Best solution by Stack Overflow
- Should I make a C&C cage for my guinea pigs?Best solution by Yahoo! Answers
- How can I design a workout program for myself?Best solution by Yahoo! Answers
- Do I need a state photo ID if I already have a drivers liscense?Best solution by Yahoo! Answers
- Where can I get a copy of my last year's tax form?Best solution by Yahoo! Answers
Just Added Q & A:
- How many active mobile subscribers are there in China?Best solution by Quora
- How to find the right vacation?Best solution by bookit.com
- How To Make Your Own Primer?Best solution by thekrazycouponlady.com
- How do you get the domain & range?Best solution by ChaCha
- How do you open pop up blockers?Best solution by Yahoo! Answers
For every problem there is a solution! Proved by Solucija.
-
Got an issue and looking for advice?
-
Ask Solucija to search every corner of the Web for help.
-
Get workable solutions and helpful tips in a moment.
Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.