After a bit of a break, I'm returning to finish the Advent Calendar. In Day 13: Distress Signal, we sort packets and learn about the InstanceSigs Haskell language extension.
In Day 12: Hill Climbing Algorithm, we write Dijkstra's algorithm from scratch!
In Day 11: Monkey in the Middle, we carefully watch the items thrown from monkey to monkey. But did you see the moonwalking bear?
In Day 10: Cathod-Ray Tube, we simulate the processer of a small device using the State monad. Plus, we use some fancy characters for printing.
In Day 9: Rope Bridge, we simulate a swinging rope with recursive rules.
In Day 8: Treetop Tree House, we use the list monad to simulatenously step in any of four cardinal directions.
After taking a break for a few days, we return for Day 7: No Space Left On Device, where we parse and parse again.
In Day 6: Tuning Trouble, we scan through a string looking for subsets of unique characters.
In Day 5: Supply Stacks, we watch a crane push and pop items from several stacks.
Following up on Day 4, I refactor my parsing function to reduce repetition.
In Day 4: Camp Cleanup, we write a bunch of code to avoid doing extra work. Wait a minute…
Following up on Day 3, I explore some functions to split strings in half.
In Day 3: Rucksack Reorganization, we help our elfen friends identify shared features across sets.
In Day 2: Rock Paper Scissors, we evaluate the merits of using an encrypted strategy guide to cheat our new friends.
In Day 1: Calorie Counting, we start our expedition into the jungle. I describe and annotate my solution.
I'm solving Advent of Code's 2022 puzzles using Haskell.
For many years, I left this website largely unmaintained, and it continued working just fine. After all, it's primarily a set of static files which should not demand any attention. So, I consider that a win.
Today, however, I underwent a larger maintenance task, and moved this site from Heroku (with a custom Node.js server with Express) to Vercel (with a Next.js backend). Here's looking forward to many more years of zero maintenance.
I like writing blog posts. You may not realize that, considering I write about two posts per year. Whoops. The thing is, a lot of work goes into writing a single post; there is thinking of an idea, sketching an outline, composing the post itself, and finally marking it up and publishing it.
Most of that seems inevitable, but that last piece, the markup, feels like wasted effort. More effort makes writing less enjoyable and widens the gaps between posts, simply because I don't want to be bothered with that hassle again. In an ideal world, I would like to just write the words and post them. Everything else (the paragraph tags, links to external sites, emphasis markers, etc) would be automatically added or inferred based on context. So, what is stopping me from living in that utopia?
Earlier this week, I came across an article on Butterick's Practical Typography that was about 4K monitors. Or, so I thought when I started reading it. I had glossed over the title, so about halfway down I was hit by some sudden Cantor. Discrete Math!
A lot of people would have a lot of different reactions to that, but I was pleasantly surprised. The question posed was this: If you keep doubling the resolution of a computor monitor, how many pixels will the infinitely divided screen have?
I read an interesting post the other day by Ben Nadel (@BenNadel). It used a relatively simple cache module to illustrate
this behavior in the revealing module pattern
. It's a good read, and it got me thinking further about public and private methods and
this. The most thought provoking aspect for me, though, was the almost-footnote at the end: this doesn't work for private methods.
Can we fix that? Maybe.
After getting my Raspberry Pi up and running last week, I was really pumped to continue on, find a project, and put it to good use. I spent this weekend exploring the world of Web Audio. Even working with browsers and WebRTC all day at work, I am constantly surprised by the ease with which HTML5 lets you wield a lot of power to do cool things. Here is how to do one thing I learned this weekend: Playing a FLAC file from one computer to another using WebRTC.
It has been over a year since curiosity got the best of me and I purchased a Raspberry Pi. Due to a bad SD card, it was originally shelved, one operating system short. The past couple days, though, the Pi came off the shelf and back into the workshop (read: corner of my desk). I'm still not sure entirely what I am going to build with the Pi (perhaps something music related), but I am happy to say that I managed to get it primed and ready for development. Here's the rundown of the setup process.
Browsers nowadays provide lots of ways to personalize your experience. Firefox has its Add Ons and Chrome has Extensions. These can be great for enhancing your browser, from increasing productivity, personalizing themes, or even adding just a little humor to your day to day surfing, but they can also be dangerous.
Here lies my first contribution to the Vanilla Web Diet. I first coded up this accordion list several months ago as part of the GetOnSIP project. No simple widget can be perfect for every use case. In this post, I walk through a simple version of a collapsible accordion list, with customization ideas to come later.
Hi. My name is Will Mitchell, but I often go by wakamoleguy. Today marks the launch of wakamoleguy.com, my new site. Okay, so it has been up since Saturday, but it didn't have any content on it until now.
As I write and accumulate examples, I hope to host those on wakamoleguy.com as well. Experiments and proofs of concept may show up here, too. In the end, I hope it will become my home on the web.
If you experience a delay when visiting this site, please excuse me. I am using free Heroku hosting which takes five or ten seconds to wake up after inactivity. Anyways, thank you for putting up with it, welcome, and enjoy your stay!