@alrj don't optimise early as my architect friends always said πŸ˜„

Also I'm very tempted to dive into the world of #Xi8088

@alrj Wow, congratulations! You did much better on the #Xi8088 than I did on the #Ti92 :)

I know you don't usually post code, but this is one where I'm really curious to see what you did!

I've now also completed part 2 of "Factory" - Day 10 of #AdventOfCode in #TurboPascal on the #Xi8088 !

It takes about 25 minutes to run and was quite the challenge to write, I had to learn more than I was prepared to.

But with it, that's all 12 days completed, all in #Pascal, all on the #i8088.

What a journey! Thank you so much, @ericwastl

Oh, and I'm never doing Advent of Code in Pascal again! That was really a dumb idea πŸ˜…

#Retrocomputing #DOScember

I just completed "Christmas Tree Farm" - Day 12 of #AdventOfCode in #TurboPascal. Only in #DOSBox for now, until I get back home and run it on the real #Xi8088 hardware.

I can already tell that parsing the input file will take a lot longer than solving!

(No spoiler in the picture)

#Retrocomputing #Pascal #DOScember

I just completed "Reactor" - Day 11 of #AdventOfCode in #TurboPascal on the #Xi8088

Thankfully, the problem is constrained enough that the memoization cache is actually very small. This is a good thing for our little 8088.

Both parts solve really fast, but the first version of my input parsing procedure was taking a whopping 42 seconds πŸ˜… I just couldn't leave it like that.

#Retrocomputing #Pascal #DOScember

Look, ma! No recursion! But no part 2 yet either...

I completed part 1 of "Factory" - Day 10 of #AdventOfCode in #TurboPascal on the #Xi8088

I'm pleased with my solution, where parsing the input file takes longer than solving (12.30 vs 10.39 sec).
It's built around a short but non-trivial procedure written with the help of a StackOverflow post. Spoiler in picture.

Now, it looks like I have a few things to learn before I can attempt to solve part 2...

#Retrocomputing #Pascal #DOScember

I just completed "Movie Theater" - Day 9 of #AdventOfCode in #TurboPascal on the #Xi8088 and I'm quite proud of my solution!

I got the logic right for part 2 nearly immediately but plain brute force was way too slow: I had to crank up the CPU speed in #DOSbox quite a bit just to test it.

Doing some precalc (likely not the same as what other people did πŸ˜‰) on the input and re-thinking data structure helped a huge lot, going from 1 hour to less than 4 minutes!

#Retrocomputing #Pascal #DOScember

Oh my goodness, I did it. What a day!

I spent the entire day to solve "Playground" - Day 8 of AdventOfCode in #TurboPascal on the #Xi8088 and I had a blast!

I got all the logic right on first try for both parts, but the big question was: How do you sort up to a million entries on a machine that can't even store ten times less in memory, in a language where your arrays are less than 64KiB ? 🀯

Obvious answer is "you don't", but then what? πŸ˜…

So happy!

#Retrocomputing #Pascal #DOScember

I just completed "Laboratories" - Day 7 of #AdventOfCode in #TurboPascal on the #Xi8088 computer.

Part 2 fits inside the same loop as part 1 with very few modifications.

Then I could make it read the file line by line as it goes, instead of building the entire map in memory.

By keeping track of the left and right limits of potential change, I could also reduce the memory accesses.

With 1.3 second of total runtime, I'm very happy with my solution today !

#Retrocomputing #Pascal #DOScember

I just completed "Trash Compactor" - Day 6 of #AdventOfCode in #Turbo Pascal on the #Xi8088 computer.

Once again, we face input lines too long to fit in a 'string' and numbers too big to fit in a 'longint' (these are only 32-bit signed), but I'm getting used to all that so in the end, today was pretty much uneventful.

Let's take a moment to thank our very good friend the #i8087 artithmetic coprocessor for its help!

#RetroComputing #Pascal #DOScember