Risto Viitanen
dilaz.bsky.social
Risto Viitanen
@dilaz.bsky.social
My super powers include writing AND reading regex. Into software hacks, being lazy and Information security. Uses tabs when coding. Creator of the original Norppalivebot
❤️ our future AI overlords
#norppalive­ssä näköjään tapahtuu tänää jotain, näyttäis 5min välein tulevan joku kuva ruutuun­­­
May 13, 2025 at 6:58 AM
Miten joka #norppalive­ssä on tommonen norpan muotonen kivi?!
May 2, 2025 at 6:55 PM
First test run of this newly trained YOLOv11n-model detecting norppas (or saimaa ringed seals) seems to be working pretty well

#norppalive
February 1, 2025 at 5:54 PM
Uutta norppabottia kouluttaessa, kun tutkii vanhoja hakemistoja, löytyy välillä aarteita
January 25, 2025 at 9:43 AM
#AdventOfCode day 16 done and it was pretty quick with the help of pathfinding-crate, which felt a bit like cheating

For some reason the last test fails, but I still got the correct solution

github.com/Dilaz/advent...
github.com
December 17, 2024 at 6:52 PM
Day 15 of #adventofcode done.

Starting to take a bit too long to solve these puzzles so I might have to give up soon 😅

github.com/Dilaz/advent...
github.com
December 17, 2024 at 4:35 PM
Day 14 of #AdventOfCode was pretty.. different. I think I got a bit lucky and guessed how the part 2 works, but it's not super fast solution, takes about 75ms to run

github.com/Dilaz/advent...
github.com
December 15, 2024 at 8:47 PM
Had a few busy days, but here are solutions for day 12 & 13 of #adventofcode

Day 12 part 2 is my slowest solution, it takes around 17ms to run but I think day 13 part 2 is one of the faster ones (51µs) if you don't count parsing the data (47µs)

github.com/Dilaz/advent...
github.com/Dilaz/advent...
github.com
December 15, 2024 at 6:50 PM
I've completed "Plutonian Pebbles" - Day 11 - Advent of Code 2024 #AdventOfCode adventofcode.com/2024/day/11

I tried "cached" crate, but it messed up my benchmarks, so I made my own cache.

github.com/Dilaz/advent...
Day 11 - Advent of Code 2024
adventofcode.com
December 11, 2024 at 3:24 PM
Another busy year, apparently I've been watching Twitch about 52 hours per day on average!

#twitchrecap
December 10, 2024 at 3:40 PM
Day 10 of #adventofcode was easier than 9. Actually due to my lazy solution, part 2 is faster than part 1. The only difference is that part 1 needs to get the unique routes and part 2 just counts them all (261µs vs. 187µs)

github.com/Dilaz/advent...
github.com
December 10, 2024 at 1:54 PM
Finally got #adventofcode day 9 part 2 working, I have no idea why it was so hard for my brain.

Also changed things a bit in the project and I'll try to fix up the rest of the days to the same format to have a separate lib, main & benchmarks for each day

github.com/Dilaz/advent...
github.com
December 10, 2024 at 12:26 PM
Back to microseconds in #adventofcode day 8
Spent way too many hours debugging too low result on part 1 and the issue was, that I needed '0'..='9' instead '0'..'9', which left out 9.
You get a warning for that by adding:
`"rust-analyzer.check.command": "clippy"`
to VSCode

github.com/Dilaz/advent...
github.com
December 8, 2024 at 5:32 PM
Pretty happy with #adventofcode day 7 solution. Had some issues getting the correct answer due to a premature optimization, which I didn't think through:
Who would have known that x + 1 is larger than x * 1?

But now part 1 runs in 1.8ms and part 2 in 5.8ms

github.com/Dilaz/advent...
github.com
December 7, 2024 at 3:01 PM
#adventofcode day 6 done! Managed to optimize part 2 from 2.5s runtime to 125ms with the help of Rayon lib & other stuff, but I'm sure there's still something I could do to make it faster

github.com/Dilaz/advent...
github.com
December 6, 2024 at 1:06 PM
Day 5 of #adventofcode done and it's at least less hacky than they day4 solution

github.com/Dilaz/advent...
github.com
December 5, 2024 at 11:58 AM
Day 4 of #adventofcode is my laziest solution so far since I really dislike these kind of tasks, but at least it works and it is ⚡Blazingly fast⚡

github.com/Dilaz/advent...
github.com
December 4, 2024 at 9:51 AM
Made a lazy regex solution for #adventofcode day 3 and then a faster/more optimized one with nom.

It's not like the regex solution was slow or anything, but the run time dropped from 0.004s to 0.001s

github.com/Dilaz/advent...
github.com/Dilaz/advent...
github.com
December 3, 2024 at 5:02 PM
#adventofcode day 2 done and almost got to use the Rayon lib, but it just got slower with that 😅

github.com/Dilaz/advent...
github.com
December 2, 2024 at 9:49 AM
Day 1 done in Advent of Code, let's see if I can manage to solve the first 10 puzzles this year

github.com/Dilaz/advent...
github.com
December 1, 2024 at 10:44 AM
I guess I'll try to move all my bots (@norppalivebot.bsky.social and others) to Bluesky and in the future, some new bots I've been thinking about doing
November 28, 2023 at 2:00 PM
Hello, world!
November 17, 2023 at 8:11 AM