comp.lang.ada
 help / color / mirror / Atom feed
From: "Jeffrey R. Carter" <spam.jrcarter.not@spam.not.acm.org>
Subject: Re: Advent of Code Day 6
Date: Mon, 7 Dec 2020 14:32:19 +0100	[thread overview]
Message-ID: <rqlat3$hsl$1@dont-email.me> (raw)
In-Reply-To: <10a26bc3-9f76-4857-be6d-ec00fccbdbc9n@googlegroups.com>

On 12/7/20 11:55 AM, Maxim Reznik wrote:
> In my solution I use a custom type - a boolean flag for each character. It takes 26 bytes (or even bits if you add `with Pack` aspect) and should be quite fast. Having this type it's easy to do `and` and `or` between such maps:

Fast? I have made no attempt to make my solutions fast, and the slowest one gives

real	0m0.059s
user	0m0.007s
sys	0m0.000s

using the Linux "time" command. All of them have a user time < 10 ms. Almost all 
the real time is doing I/O. And there are no timing requirements.

"Fast" should not be something anyone is worrying about.

-- 
Jeff Carter
"Ah, go away or I'll kill ya."
Never Give a Sucker an Even Break
100

      reply	other threads:[~2020-12-07 13:32 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-06  8:39 Advent of Code Day 6 John Perry
2020-12-06 11:07 ` Jeffrey R. Carter
2020-12-06 19:37   ` John Perry
2020-12-07 10:55     ` Maxim Reznik
2020-12-07 13:32       ` Jeffrey R. Carter [this message]
replies disabled

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