Pony devcontainer.json
Here’s a bare bones VS Code devcontainer.json for Pony, mostly so that I can easily copy and paste it in the future. { "name": "Pony", "image": "docker.io/ponylang/ponyc", "settings": {}, "extensions": [ "npruehs.pony" ] }
Here’s a bare bones VS Code devcontainer.json for Pony, mostly so that I can easily copy and paste it in the future. { "name": "Pony", "image": "docker.io/ponylang/ponyc", "settings": {}, "extensions": [ "npruehs.pony" ] }
Day 3’s problem has us work out what the most common bit is per column concatenating them to find the gamma value. The epsilon value is the inverse. Given the following input, 00100 11110 10110 10111 10101 01111 00111 11100 10000 11001 00010 01010 we’d have a gamma of 10110 and epsilon of 01001. The result is the product of the gamma and epsilon. buildString provides a string builder as an expression, letting us yield characters and strings....
Developing with containers is now simple with VSCode’s Remote Development extension. Any serious project where I use VSCode now has a devcontainer.json (including this blog), yet I’ve never been happy about using Docker on my personal machines. The install process is a little invasive, containers run as root by default, and I never liked the daemon running on my laptop all of the time. I recently switched my desktop and laptop from Fedora to Ubuntu, as my wife is very close to trying a Linux over Windows and I wanted to see what the state of the world was like for non-technical folk (quick summary - once setup, it’s pretty good), and with a nice clean system I wanted to see if I could avoid using Docker and do everything with Podman....
Recently on Hacker News I saw that Zig 0.9.0 was released and it rekindled my interest in this language. Besides reading the Why Zig When There is Already C++, D, and Rust? page and a few other pages from the docs I’ve never tried to use it, so instead of moving on to day 3 in Kotlin I thought I’d start again (at least for one day) in Zig. I haven’t read all the docs yet, so there’s no doubt that what I’ve come up with is not ideal....
It’s the 14th and I’m just writing about day 2, which is pretty much what I expected to happen. If the trajectory is linear it’s not too bad, I’ll at least be done in time for AOC 2022. Day 2’s problem has us read commands and update our position with the following rules: forward X increases the horizontal position by X units. down X increases the depth by X units....