Big Integers Native Snap Library that doesn't use JavaScript

I had an idea :slight_smile:

Why not create a Big Integer Library that's written purely with Snap! that doesn't use the functionalty of the BigInt in JS

As a learning/discussion exercise :slight_smile:

To set the ball rolling I'm thinking that to avoid accidental corruption of a value into floating point - we'd need to hold a SnapBigInt (as my proposed name for them) as either lists of digits (or a string with an alpha prefix such as BSI123456789123213787391883019801298309281290)

And first goal would be to create a plus reporter, hen minus, then multiply then....????

Any thoughts/ideas welcome :slight_smile:

That does sound like a great exercise, but bear in mind that the existing library provides exact rationals and complex numbers as well as bignums. (And that these days JS has native bignums.)

It's just an idea for a learning exercise to find good solutions- not intended to be a replacement lib :slight_smile:

im gonna do this lol


This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.