snabelen.no is one of the many independent Mastodon servers you can use to participate in the fediverse.
Ein norsk heimstad for den desentraliserte mikroblogge-plattformen.

Administrert av:

Serverstatistikk:

451
aktive brukere

#nim

ett innlegg1 deltaker0 innlegg i dag

For those annoyed about Dorsey being at #fosdem2025 - i totally agree.
If you're going to join the protest, I support you with that too.
However, please do not forget that other things are going on at the same time at Dorsey's Keynote. Don't let your anger he is there take away from other people who have put in effort to create something to share with our community.
I'm not sure where I will be yet, but perhaps I'll take a look at the Developer Rooms where #Nim have some things going on

https://fosdem.org/2025/schedule/event/fosdem-2025-6229-nim-c-reaching-the-stars-by-standing-on-the-shoulders-of-giants/

fosdem.orgFOSDEM 2025 - Nim & C: Reaching the stars by standing on the shoulders of giants

Finally got to use my utilities library for this one, I didn't really have to make any changes in it.

Part 2 here is really quite slow, but it completes in less than a minute, so I don't really feel like optimising it, it's a very straight foreward stupid way of doing it, but it just works, so I'm not really that bothered by it :p This time at least naming was better, and as a result it's so much easier to read the code :)

https://paste.sr.ht/~sotolf/f5503c4fb91e7d25fdbe59edc831a1666498262e

I quite enjoyed this one, although I have to say that naming did not go very well here, variables have terrible names that are only half consistent with the problem, and how it's described, I started out using terms from the Problem description, and slowly migrated into names that made sense to me, which made it kind of a mess.

Parsing was rather elegant I feel, and reordering here I basically bubbled up numbers until the last of the ones that it needed, and it works nicely, even though I'm a bit unsure if this would work if the queues were a bit more antagonistically set up.

https://paste.sr.ht/~sotolf/48ad7954ad973858410a46425c9fa27bcd12486d

#adventofcode #nim day05

Replied in thread

@chainq OK, so you got 244 BYTES Hunk executable with this?
Holy hell, you don't need to seel it any longer, I already bought!

And the fact you can simply define OS calls as function calls just by passing LVOffsets and registers as params? Damn, I thought about doing similar thing with #Nim macros, but that's definitely more elegant than mine.

Also, it's not that bad, looks better than equivalent C counterpart, more signal, less noise.

Here are two screens (cropped for clarity).
The top is from #Amiga and the bottom is from #AtariST.

Both run from the same codebase in #Nim, yet the code is completely different. While I appreciate Amiga for its awesome hardware and capabilities, the AmigaOS API is... ugh, I can't find the English word to describe it. It's bad.

Yet, the ST/STe hardware is so basic it feels like they just glued DMA on 68000 SBC in a weekend. But their APIs? I wish it could swap places with AmigaOS somtimes.

For 2024, I solved Advent of Code in 25 different languages. Was a fun project, sometimes a bit (very) painful (*glances at Erlang and Zig*).

Code (bottom of post) and summary for each language:
blog.aschoch.ch/posts/aoc-2024

Keep in mind that I used most of these language for a few hours tops, so my judgement is very much subjective.

What's your favourite of the bunch?

blog.aschoch.chAdvent of Code 2024 – 25 Languages<!-- --> • Alexander Schoch's BlogI solved Advent of Code 2024 with 25 different programming languages

I'm starting a small closed play-test for the #playdate game I've been developing in #nim. It’s an action arcade game where players take on the role of an archer defending their tower against waves of enemies. If you own a playdate and are interested in participating, please fill in the following form:

forms.gle/q61UTQCAfGCNAZTc8

Note that I am keeping the player pool small for now, as I am still polishing and balancing aspects of the game. And thank you! #indiedev