Author Topic: Advent of Code  (Read 111511 times)

Oaky

  • ACME Fire Safety Officer
  • Audax Club Mid-Essex
    • MEMWNS Map
Re: Advent of Code
« Reply #500 on: 15 December, 2017, 05:48:24 pm »
(click to show/hide)

(click to show/hide)
You are in a maze of twisty flat droves, all alike.

85.4 miles from Marsh Gibbon

Audax Club Mid-Essex Fire Safety Officer
http://acme.bike

Re: Advent of Code
« Reply #501 on: 15 December, 2017, 09:56:56 pm »
Day 15

I thought that Javascript might struggle doing modulus 231. It didn't, and only takes a few seconds to run.

The whole point about day 13 was that it took too long to run when brute-forced. When reading day 15, I thought that the maths that is simple in principle would have some feature that would trip up the simple approach.
Quote from: Kim
Paging Diver300.  Diver300 to the GSM Trimphone, please...

David Martin

  • Thats Dr Oi You thankyouverymuch
Re: Advent of Code
« Reply #502 on: 15 December, 2017, 11:13:32 pm »

Far too busy to do yesterday and today till now.

Day 14 was easy for part 1,
(click to show/hide)

Day 15 was straightforward
(click to show/hide)
"By creating we think. By living we learn" - Patrick Geddes

Re: Advent of Code
« Reply #503 on: 16 December, 2017, 07:53:22 am »
day 16 part 2 is proving difficult.....
Quote from: Kim
Paging Diver300.  Diver300 to the GSM Trimphone, please...

Re: Advent of Code
« Reply #504 on: 16 December, 2017, 08:10:00 am »
day 16 part 2 is proving difficult.....
You're not the only one stuck on that

(click to show/hide)
Quote from: tiermat
that's not science, it's semantics.

David Martin

  • Thats Dr Oi You thankyouverymuch
Re: Advent of Code
« Reply #505 on: 16 December, 2017, 10:03:52 am »
I am finding part 2 challenging
(click to show/hide)
"By creating we think. By living we learn" - Patrick Geddes

Re: Advent of Code
« Reply #506 on: 16 December, 2017, 10:40:21 am »
I didn't think that would work.

(click to show/hide)
Quote from: tiermat
that's not science, it's semantics.

David Martin

  • Thats Dr Oi You thankyouverymuch
Re: Advent of Code
« Reply #507 on: 16 December, 2017, 10:45:00 am »
OK, simple error
(click to show/hide)
"By creating we think. By living we learn" - Patrick Geddes

David Martin

  • Thats Dr Oi You thankyouverymuch
Re: Advent of Code
« Reply #508 on: 16 December, 2017, 10:45:32 am »
I didn't think that would work.

(click to show/hide)
That is now obvious. :)
"By creating we think. By living we learn" - Patrick Geddes

Re: Advent of Code
« Reply #509 on: 16 December, 2017, 12:57:50 pm »
Bit late to it today...

(click to show/hide)

It's annoying as I'm solving the majority of these in a faster time than the 100th person on the main leaderboard (today I would have scraped into the top 10). But I guess quite a few other people are too (who also just don't happen to be at their computer at midnight EST).
"Yes please" said Squirrel "biscuits are our favourite things."

Re: Advent of Code
« Reply #510 on: 16 December, 2017, 04:43:35 pm »
I didn't think that would work.

(click to show/hide)

(click to show/hide)
Quote from: Kim
Paging Diver300.  Diver300 to the GSM Trimphone, please...

Ben T

Re: Advent of Code
« Reply #511 on: 16 December, 2017, 05:25:07 pm »
(click to show/hide)

Re: Advent of Code
« Reply #512 on: 16 December, 2017, 05:31:18 pm »
Day 16
(click to show/hide)
Quote from: Kim
Paging Diver300.  Diver300 to the GSM Trimphone, please...

Ben T

Re: Advent of Code
« Reply #513 on: 16 December, 2017, 05:38:58 pm »
Day 16
(click to show/hide)

(click to show/hide)

Re: Advent of Code
« Reply #514 on: 16 December, 2017, 09:11:40 pm »
Day 16
(click to show/hide)

(click to show/hide)

(click to show/hide)
Quote from: Kim
Paging Diver300.  Diver300 to the GSM Trimphone, please...

Re: Advent of Code
« Reply #515 on: 16 December, 2017, 10:36:19 pm »
(click to show/hide)

(click to show/hide)
Quote from: tiermat
that's not science, it's semantics.

Re: Advent of Code
« Reply #516 on: 17 December, 2017, 06:53:36 am »
Day 17 was quite straightforward.
(click to show/hide)
Quote from: Kim
Paging Diver300.  Diver300 to the GSM Trimphone, please...

Re: Advent of Code
« Reply #517 on: 17 December, 2017, 08:41:39 am »
Day 17 was quite straightforward.
(click to show/hide)

64 characters for part 2, including input data.  ;D

(click to show/hide)
Quote from: tiermat
that's not science, it's semantics.

Re: Advent of Code
« Reply #518 on: 17 December, 2017, 09:59:29 am »
(click to show/hide)

(click to show/hide)
"Yes please" said Squirrel "biscuits are our favourite things."

Re: Advent of Code
« Reply #519 on: 17 December, 2017, 10:05:54 am »
(click to show/hide)

64 characters for part 2, including input data.  ;D

I can get it down to 84 in perl, but then I'm not very good at code golf.
"Yes please" said Squirrel "biscuits are our favourite things."

Re: Advent of Code
« Reply #520 on: 17 December, 2017, 10:43:24 am »
64 characters for part 2, including input data.  ;D

I can get it down to 84 in perl, but then I'm not very good at code golf.

I look forward to comparing line noise tomorrow!
Quote from: tiermat
that's not science, it's semantics.

David Martin

  • Thats Dr Oi You thankyouverymuch
Re: Advent of Code
« Reply #521 on: 17 December, 2017, 02:01:18 pm »
17a was quite straightforward.
17b required minor thought but eventually succumbed to brute force
(click to show/hide)
"By creating we think. By living we learn" - Patrick Geddes

Re: Advent of Code
« Reply #522 on: 17 December, 2017, 02:17:44 pm »
17a was quite straightforward.
17b required minor thought but eventually succumbed to brute force
(click to show/hide)

(click to show/hide)
Quote from: Kim
Paging Diver300.  Diver300 to the GSM Trimphone, please...

David Martin

  • Thats Dr Oi You thankyouverymuch
Re: Advent of Code
« Reply #523 on: 17 December, 2017, 02:24:39 pm »
pretty much the same here. Took a bit longer than 3 seconds (about 10 or so)
"By creating we think. By living we learn" - Patrick Geddes

Re: Advent of Code
« Reply #524 on: 17 December, 2017, 02:32:26 pm »
Don't you need to increment buf_len?

My Perl version took 18 seconds with a grep BLOCK, but that's because grep allocates the whole list before it starts. Turning that into a for(RANGE) runs in 8 seconds. Oh and I'm down to 61 characters in the golf version  :)
Quote from: tiermat
that's not science, it's semantics.