Human Resource Machine (Steam):
Too see it in action check out
this webm i made or watch
NWR video of James Jones playing the game.
I am cautious about "playing" these types of programming puzzle games. Being software engineer who does programming for living the idea of a game that forces you to work, calls it entertainment AND doesn't pay you is preposterous. It is like that picture where
dude works on a forklift all day and comes back home to relax and play forklift simulator videogame.
Still i started HRM thinking i can finish it in a few days time. Because game features rather basic machine and starting puzzles are basically just exercises straight out of computer science textbooks i thought i can be done with it very quickly. And for many tasks i did, writing out the perfect (both in code size and speed) solution literally on my first try.
However few puzzles were much harder and had me trying to solve them in the span of several nights. I also had to write several vastly different solutions depending if i aimed for speed or tried to shorten the program.
Puzzle when you are asked by to split digits in a number (so that you get "437" and output "4 3 7") gave me a trouble, especially in efficiency challenge. It requires division by 100s and 10s but HRM can't do division by itself, and you have to emulate it by subtracting subtrahend repeatedly until you reach zero or negative value. To fullfill speed requirement i went way, way overboard with
loop unrolling and had to wrote a program so long it reached program limit:
Another interesting problem was sorting. Sorting is a classical task in Computer Science and as a student i spent a lot of time studying various methods and reading "
Art of Programming" which had an entire chapter dedicated to sorting alone.
Because i tend to gravitate to the simplest algorithms i first wrote
selection sort, it was short (33 commands) but not fast enough. Then i started over and did rather complicated
heap sort which theoretically should be much faster, however because of primitive nature of commands (modern processors can access memory at address 2x+1 all in one command, but in HRM you have to write like 8 commands to do the same) and input data being too short my code ended up slower instead. Then i restarted again and wrote
insertion sort algorithm which did the trick.
Re-learning all these things was kinda fun. Just like 15 years ago, i was once again stunned by the cleverness of heap sort algorithm.
The final puzzle with
prime factors turned out to be much easier than i thought it was. For the first day i thought that i HAVE to actually calculate prime numbers (at least first 7 of them), but apparently i didn't, because the way algorithm works it outputs prime numbers by itself naturally.
Game's art style and atmosphere with story vignettes helped to make it more of a fun game. Background ambient music very old by the end and i was just muting it.
Overall: this "game" might be interesting if you want to learn the basics of CS and will be hard enough if you go for optimized solutions. Not sure if i recommend to people who just want to have a good time though, because i fully realize that spending an hour trying to optimize the program by one command is not everyone's idea of fun.