GithubHelp home page GithubHelp logo

adotsch / aoc Goto Github PK

View Code? Open in Web Editor NEW
13.0 1.0 4.0 3.54 MB

Advent of Code solutions in KDB/Q

q 91.72% Python 0.81% APL 0.15% Shell 0.17% C 7.14%
advent-of-code-2020 kdb-q kdb kx advent-of-code-2021 advent-of-code-2015 advent-of-code-2016 advent-of-code-2022

aoc's Introduction

Advent of Code solutions

This repository contains my Q solutions to the Advent of Code puzzles of year 2015, 2016, 2020, 2021, 2022 and 2023.

Cheating

This repository is not intended to promote or otherwise encourage cheating.

If you are competing you should always submit your results based on your own work.

Other solutions in K/Q/APL

Repsitory Language
Pavlo Piatkovskyi Q
Mark Street Q
Cillian Reilly Q
Sean Ang Q
avkoshel Q
Tadhg Downey Q
lukebrit27 Q
Angus Wilson Q
Péter Györök Q
Rory Kemp K/Q, APL
Nick Nickolov (NGN) K
Aaron W. Hsu APL
Stefan Kruger APL
Peter Vernigorov APL/K

aoc's People

Contributors

adotsch avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

aoc's Issues

day 11

you can use arthur's sparse.q
to create the same table you have, but marching over the matrix all at the same time should be the fastest by of finding neighbors.
sm:{([]row:where count each i;col:raze i;val:raze x@'i:where each x<>0)}

c:raze "L"=i;l:raze "#"=i;
s:{(count x;count first x)} i
d:{x!s sv flip x}flip s vs til prd s
p:flip key d
m:{{?[c y;y;d flip x+s vs y]}[x]/[d flip x+y]}
n:(1_{x cross x}0 1 -1) m: p
seat:{c*(5>a)&x|0=a:sum 0^x n}
sum seat over l

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.