comp.lang.ada
 help / color / mirror / Atom feed
From: Stephen Leake <stephen_leake@stephe-leake.org>
Subject: Re: advent of code day 10
Date: Fri, 11 Dec 2020 09:04:27 -0800	[thread overview]
Message-ID: <86r1nwp944.fsf@stephe-leake.org> (raw)
In-Reply-To: c2898e67-d978-4ed9-bdaf-ff0cf6cf22fen@googlegroups.com

Jared Summers <jtsummers@gmail.com> writes:

> On Thursday, December 10, 2020 at 8:39:36 PM UTC-7, Stephen Leake wrote:
>> I cheated; the final total is larger than 64 bits, so I just printed out 
>> the factors and used Emacs built-in bignums to compute it. I assume 
>> there is an Ada bignums package out there, and the compiler has one that 
>> full Ada 2020 will expose, but I'm trying to catch up, so did not look. 
>
> My answer was able to fit in a Long_Long_Integer on my machine. But,
> due to a bug, I did play with the Big_Integers package. It worked
> well, and I'd recommend taking a look at it for upcoming problems.

Yes; GNAT Community 2020 with -gnat2020 and -gnatX supports
Ada.Numerics.Big_Integer. I updated my solution to use that.

-- 
-- Stephe

  reply	other threads:[~2020-12-11 17:04 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-11  3:39 advent of code day 10 Stephen Leake
2020-12-11  5:40 ` Jared Summers
2020-12-11 17:04   ` Stephen Leake [this message]
2020-12-11  7:22 ` gautier...@hotmail.com
2020-12-11 14:14 ` gautier...@hotmail.com
2020-12-12 20:17   ` Stephen Leake
2020-12-12 22:25     ` Jeffrey R. Carter
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox