Commit Graph

7329 Commits

Author SHA1 Message Date
Kartik Agaram 18d5bab2b6 7329 - snapshot: advent day 4 part 2
I've found two bugs in SubX libraries:

1. next-word had an out-of-bounds read
2. next-word was skipping comments, because that's what I need during bootstrapping.
I've created a new variant called next-raw-word that doesn't skip comments.
These really need better names.

We're now at the point where 4b.mu has the right structure and returns
identical result to 4a.mu.
2020-12-04 23:02:53 -08:00
Kartik Agaram 8a8db34f25 7328 - advent day 4 part 1
Bug #1: forgot to process final passport
Stupid mistake #2: was reporting invalid rather than valid passports
2020-12-04 21:01:59 -08:00
Kartik Agaram 2d14f6c971 7327 2020-12-03 21:49:03 -08:00
Kartik Agaram f2ee237eea 7326 2020-12-03 21:43:21 -08:00
Kartik Agaram 6c7d9300e2 7325 - tile: start implementing function editing 2020-12-03 21:22:32 -08:00
Kartik Agaram 0cc1be4eee 7324 2020-12-02 22:33:39 -08:00
Kartik Agaram ed59e2eda9 7323 - advent day 3 done
Stupid mistake; I missed one slope in the question.
2020-12-02 22:32:27 -08:00
Kartik Agaram 50973ad178 7322 - snapshot: advent day 3 part 2
Answer isn't right.
2020-12-02 22:21:07 -08:00
Kartik Agaram 124f515826 7321 - advent day 3 part 1 2020-12-02 22:12:55 -08:00
Kartik Agaram 36b4bf1f1b 7320 - snapshot: advent day 3 part 1 2020-12-02 22:08:37 -08:00
Kartik Agaram dce3ea75f9 7319 2020-12-02 19:37:36 -08:00
Kartik Agaram f60ebed0fb 7318 - advent day 2 done
Funny story: I got the right answer for part 1 even though I missed the
':' in the line format. But of course that didn't work for part 2.
2020-12-02 19:36:10 -08:00
Kartik Agaram a41a6eadd1 7317 - advent day 2 part 1
https://adventofcode.com/2020/day/2
2020-12-02 19:20:06 -08:00
Kartik Agaram 74bc598c44 7316 2020-12-01 01:19:07 -08:00
Kartik Agaram 3d291822ca 7315 2020-12-01 01:03:30 -08:00
Kartik Agaram 4e8daa6a0e 7314 2020-12-01 01:02:12 -08:00
Kartik Agaram 05ad07b63e 7313 - advent: day 1 done 2020-12-01 01:01:49 -08:00
Kartik Agaram 69f4c36b71 7312 - advent: snapshot of 1b 2020-12-01 00:54:09 -08:00
Kartik Agaram 8bb5d26cf1 7311 2020-12-01 00:33:12 -08:00
Kartik Agaram a06611f35c 7310 - advent day 1 part 1
In the process I had to:
* Fix a bug in reading lines from stdin into streams
* Start trailing newlines when parsing ints from streams
* Implement `find` in an array
2020-12-01 00:32:43 -08:00
Kartik Agaram 8a73ef7052 7309 - tile: parsing strings into words 2020-11-30 23:20:13 -08:00
Kartik Agaram 3c84f1ae41 7308 2020-11-29 16:52:46 -08:00
Kartik Agaram 59007fb1da 7307 2020-11-29 14:08:28 -08:00
Kartik Agaram 775f77c334 7306 2020-11-29 13:42:27 -08:00
Kartik Agaram 55dfa5b985 7305 - make float-size more consistent as well 2020-11-29 13:26:48 -08:00
Kartik Agaram e1eadf67bb 7304 - more consistent printing of floats 2020-11-29 13:13:12 -08:00
Kartik Agaram 105f14f57d 7303 - better threshold for scientific notation 2020-11-29 13:01:59 -08:00
Kartik Agaram ee3ddc3961 7302 - tile: at long last, division
Also square roots.

But there's a bug in rendering floats without precision.
2020-11-29 12:51:57 -08:00
Kartik Agaram 614b132b2e 7301 - tile: float computations now working 2020-11-29 12:45:23 -08:00
Kartik Agaram 61cfedceef 7300 - bugfix in type-checking float returns 2020-11-29 12:42:34 -08:00
Kartik Agaram 33a85545e1 7299 - bug in code-generating float returns 2020-11-29 12:20:08 -08:00
Kartik Agaram b6369d4652 7298 - slightly smarter float width 2020-11-29 12:17:23 -08:00
Kartik Agaram 6b1cde4761 7297 - tile: use floats everywhere 2020-11-29 12:17:23 -08:00
Kartik Agaram 4a280280cd 7296 - rough support for printing floats
No rounding yet, and we have a blunt way to decide when to start truncating.
2020-11-29 08:45:25 -08:00
Kartik Agaram a518d84bf4 7295 2020-11-29 03:40:12 -08:00
Kartik Agaram 8766aa12cd 7294 2020-11-28 08:31:55 -08:00
Kartik Agaram ba8ee517b7 7293 2020-11-28 08:23:15 -08:00
Kartik Agaram bbcf033aff 7292 - mu.subx: loosen copy-byte checks a bit
Without this there's no way to convert an int to a byte. And that feels
too restrictive, and gives up a lot of safe things one might want to do
with bytes. (Such as divide a number by 10 and emit the remainder as a
byte.)
2020-11-27 22:44:23 -08:00
Kartik Agaram bcd2adfbf3 7291 2020-11-27 22:27:34 -08:00
Kartik Agaram 6f65b65f7d 7290
I've wrestled for a long time with how to support integer division with
its hard-coded registers. The answer's always been staring me in the face:
just turn it into a function! We already expect function outputs to go
to hard-coded registers.
2020-11-27 21:37:20 -08:00
Kartik Agaram 704265bd3c 7289 2020-11-27 12:39:18 -08:00
Kartik Agaram 3341af3d92 7288 2020-11-27 00:26:27 -08:00
Kartik Agaram 530af63477 7287
Regression: I'd broken compare on bytes. Apparently I took away support
for bytes from numberlike-output even though I didn't need to by the end.
2020-11-27 00:17:51 -08:00
Kartik Agaram 125bfde435 7286 - mu.subx: isolate bytes from previous values 2020-11-27 00:04:54 -08:00
Kartik Agaram c165b0be5a 7285 2020-11-26 23:20:15 -08:00
Kartik Agaram 736bfe9547 7284 2020-11-26 22:34:32 -08:00
Kartik Agaram b0dfe182ff 7283 2020-11-26 21:59:28 -08:00
Kartik Agaram 7f40e8a3f6 7282 2020-11-26 21:46:46 -08:00
Kartik Agaram 896a353a7d 7281 2020-11-26 21:37:09 -08:00
Kartik Agaram 066014d4b4 7280 2020-11-26 21:23:15 -08:00