Re: numbers to text



On Tue, 11 Nov 2008 20:59:25 +0100, Jonas wrote:

A.L. wrote:

On Mon, 10 Nov 2008 11:09:35 -0800 (PST), equinox
<aditya15417@xxxxxxxxx> wrote:

On Nov 10, 8:21 am, A.L. <alewa...@xxxxxxxxxx> wrote:
On Mon, 10 Nov 2008 06:39:54 -0800 (PST), equinox



<aditya15...@xxxxxxxxx> wrote:
How do you change a list of numbers say,:

[1,6]

will give me a result of

[s,i,x,t,e,e,n]

[1,3]

will give me:

[t,h,i,r,t,e,e,n]

[1,9,0,0]

will result:

[o,n,e,t,h,o,u,s,d,n,i,n,e,h,u,n,d,r,e,d]

You change by writing program in Prolog

A>L.

yes, but I am asking how can I change it

This is your homework and you should figure it out

A.L.

P.S> You can also wait until Mr Jonas from University of Koblenz,
Germany will do this for you

Hi,

I have no solution for you, just a hint:

123 million 456 thousand 789.
--- --- ---
if you can do it with numbers <= 999 you can easy get the greater
numbers. the hundred-position is easy: one, two three ... hundred the
ten postion is easy: twenty, thirty, ...ninety the teens
(11,12,13,14,15,16,17,18,19) take seperatly the one position is easy (if
it is not in a teen): one, two, ..., nine

ok, good luck!


Another hint: the div and mod operators can be useful for such a function.

Dhu

--
Duncan Patton a Campbell is Dhu
.



Relevant Pages

  • Re: numbers to text
    ... You change by writing program in Prolog ... This is your homework and you should figure it out ... the teens take seperatly ...
    (comp.lang.prolog)
  • Re: Sleep and older children
    ... Also DD13 has never needed much sleep - while I do best with *at least* ... homework help in the library before school starts. ... believe from experience of others' with teens that being *present* and pretty ...
    (misc.kids)
  • Re: Binary to Decimal
    ... lmh86 wrote: ... > Can anyone suggest any other methods that does not implement built-in ... This sounds like some homework, ... hint you into some direction, ...
    (microsoft.public.dotnet.languages.vc)
  • Re: Which prices are fake?
    ... Of course Benford's law doesn't help here, but as a hint, it suggests ... since the trailing digits for such tend ... Martin Penderis wrote: ... > challenge to all, and if the wording sounds like homework, I would not ...
    (sci.stat.math)
  • Re: help with question
    ... Let me look at a content called a Lebesgue measure, ... PS This is not homework. ... Then look at the hint given by A N Niel in the thread "content 0". ...
    (sci.math)

Loading