Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #27395

Re: Input operands base when used in operation .

Newsgroups comp.lang.javascript
Date 2015-04-21 08:39 -0700
References <ba0f7789-1c59-4d5e-ab11-9cd2484a651e@googlegroups.com> <0489a128-71a9-4d2a-b747-c08679028a6b@googlegroups.com> <d64663f6-684f-4818-b66b-018466140e33@googlegroups.com> <83e4afe9-d41b-4ccc-90b9-2450ae909eb7@googlegroups.com>
Message-ID <5aee3d05-e13b-40c1-845b-2db2eb48eb47@googlegroups.com> (permalink)
Subject Re: Input operands base when used in operation .
From Scott Sauyet <scott.sauyet@gmail.com>

Show all headers | View raw


jonas.thornvall@gmail.com wrote wrote:

> I show you the plain conversion function and then the one to take it to 
> bignumb. I have a compare function that compare two arrays *work*, and i 
> have two arithmetic bignumb functions that takes arrays as arguments. The 
> conversion need bignumb add, mult and subt which i've implemented. I find 
> it easy to implement plain ideas, but very hard to adjust them dealing 
> with arguments and arrays. 
> 
> [ ... much code removed ... ]
> 
> How could it get so complicated?

I don't know.  

I've not  really been following your adventures in bignum very carefully.
They end up with what is to me walls of unreadable code, without any
useful explanation or challenging questions.

Because I have done something similar before in another language, I'm at
least somewhat curious, and would actually *like* to find your work
interesting.

If I understand correctly, you want a function to convert a number 
specified in one base into another.  That's fine.  But these are not
standard Javascript numbers, but your implementations of bignums.
How are these represented?  Are they arrays of integers representing
"digits" of your numbers?  If so, is the most significant or least significant digit first?  Do these represent just integers, fractions, 
fixed "decimals", or some other format?

Without understanding this, I'm not likely to dig into code I find
poorly formatted in order to find problems, nor to offer my own 
alternatives.

But I am curious, and might if I did understand your requirements
better, be willing to spend some time trying my own hand at the
issue.  (The emphasis is on _might_!)

  -- Scott

Back to comp.lang.javascript | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Input operands base when used in operation . jonas.thornvall@gmail.com - 2015-04-15 09:23 -0700
  Re: Input operands base when used in operation . Scott Sauyet <scott.sauyet@gmail.com> - 2015-04-15 13:38 -0700
    Re: Input operands base when used in operation . jonas.thornvall@gmail.com - 2015-04-16 01:27 -0700
      Re: Input operands base when used in operation . jonas.thornvall@gmail.com - 2015-04-16 03:16 -0700
        Re: Input operands base when used in operation . jonas.thornvall@gmail.com - 2015-04-16 03:22 -0700
        Re: Input operands base when used in operation . Scott Sauyet <scott.sauyet@gmail.com> - 2015-04-21 08:39 -0700
          Re: Input operands base when used in operation . Dr J R Stockton <reply1500@merlyn.demon.co.uk.invalid> - 2015-04-22 16:28 +0100
            Re: Input operands base when used in operation . Scott Sauyet <scott.sauyet@gmail.com> - 2015-04-23 04:17 -0700
              Re: Input operands base when used in operation . Dr J R Stockton <reply1500@merlyn.demon.co.uk.invalid> - 2015-04-25 22:09 +0100
                Re: Input operands base when used in operation . Scott Sauyet <scott.sauyet@gmail.com> - 2015-04-27 09:51 -0700
                Re: Input operands base when used in operation . jonas.thornvall@gmail.com - 2015-04-28 05:05 -0700
                Re: Input operands base when used in operation . Scott Sauyet <scott.sauyet@gmail.com> - 2015-04-30 08:45 -0700
                Re: Input operands base when used in operation . jonas.thornvall@gmail.com - 2015-04-30 11:17 -0700
                Re: Input operands base when used in operation . Scott Sauyet <scott.sauyet@gmail.com> - 2015-04-30 13:38 -0700
                Re: Input operands base when used in operation . jonas.thornvall@gmail.com - 2015-04-30 23:23 -0700
            Re: Input operands base when used in operation . jonas.thornvall@gmail.com - 2015-04-24 03:10 -0700
              Re: Input operands base when used in operation . Scott Sauyet <scott.sauyet@gmail.com> - 2015-04-27 09:45 -0700
          Re: Input operands base when used in operation . jonas.thornvall@gmail.com - 2015-04-24 02:54 -0700
  Re: Input operands base when used in operation . JJ <jj4public@vfemail.net> - 2015-04-18 23:17 +0700
    Re: Input operands base when used in operation . "Christoph M. Becker" <cmbecker69@arcor.de> - 2015-04-18 18:34 +0200

csiph-web