Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.javascript > #27184
| Newsgroups | comp.lang.javascript |
|---|---|
| Date | 2015-04-04 00:34 -0700 |
| Message-ID | <5e062687-8e2f-4bc3-94ce-e42df1cb1288@googlegroups.com> (permalink) |
| Subject | Javascript comparissons cause overflow |
| From | jonas.thornvall@gmail.com |
After i managed to write some functions actually doing arithmetic in bignumbers, basicly by handling them as strings where digit places read into an array. I decided to try change a previously written basechanger into also handling bignumbs. And it proved to be a much harder task than i origially thought. How do you go from compare size of integers to compare size of stored digitplaces in arrays? Also the bignumb multiplication assume that the two arrays passed to it is already parsed in the order bigger, smaller. Should i really have to move the parsing code into the multiplication, or make a function call from multiplication changing the order? I had not expect much of the code needed to be changed, except for the actual arithmetic operands with operators, interchanged with function calls. But it is alot more things like comparissons that would need to change.
Back to comp.lang.javascript | Previous | Next — Next in thread | Find similar | Unroll thread
Javascript comparissons cause overflow jonas.thornvall@gmail.com - 2015-04-04 00:34 -0700
Re: Javascript comparissons cause overflow jonas.thornvall@gmail.com - 2015-04-04 00:47 -0700
Re: Javascript comparissons cause overflow Ben Bacarisse <ben.usenet@bsb.me.uk> - 2015-04-04 16:01 +0100
Re: Javascript comparissons cause overflow John Harris <niam@jghnorth.org.uk.invalid> - 2015-04-04 17:44 +0100
csiph-web