chicken-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] Some random thoughts about calculations with base-N


From: Peter Bex
Subject: Re: [Chicken-users] Some random thoughts about calculations with base-N numbers
Date: Sun, 22 Dec 2013 15:26:09 +0100
User-agent: Mutt/1.4.2.3i

On Sun, Dec 22, 2013 at 03:23:03PM +0100, address@hidden wrote:
> Hi, 
> 
> I was fooling around a bit with conversions of base-36 to base-10 numbers.
> While the solution to convert a base-10 number to a base-36 string is pretty
> straightforward, I wonder it would be possible to make a scheme program
> calculate directly in base-36 without any string conversion.

This question makes very little sense, as your computer is calculating
in base 2.  Even when you enter numbers in base 10, these will be
converted internally to a 2's complement binary representation, usually
at compilation time.

You could write your own code which stores numbers in a base 2
representation of base 36 (ie, in individually stored digits of 36),
but I don't quite see the point.

Cheers,
Peter
-- 
http://www.more-magic.net



reply via email to

[Prev in Thread] Current Thread [Next in Thread]