Feed aggregator
Show HN: A 311 byte Klotski solver in C++
Hi all! I made a 311 byte Klotski solver in C++
So back when I first got to use a mobile phone in 2012 I used to play a lot of puzzle games. These were notoriously hard to solve (on high levels), and I always wondered how are these created, how do they find the minimum moves, how do they know its even minimal.
Now after being in a CS major for over 3 years, I finally understand these systems fairly. So I decided to make a klotski solver.
I wanted to make it fun so I stored the whole game board in an integer (uint64_t), as I like integers more than vectors. And then I got the urge to minify the engine to the max extent I could, so shrunk it down to 311 bytes from ~3.5 KB. The engine is only the searching part though.
The solver is a BFS that explores every reachable position. For the classic start it finds the best solution in 116 moves, after exploring all 25,955 reachable states in about 2-4 ms.
Here's the repo; any feedback is welcomed : ) https://github.com/Dream-World-Coder/depuzzled
Comments URL: https://news.ycombinator.com/item?id=49917607
Points: 1
# Comments: 0
Tokens Written, Tokens Read
Article URL: https://hci.prof/blog/
Comments URL: https://news.ycombinator.com/item?id=49917604
Points: 1
# Comments: 0
When Did You Last Write Code?
Article URL: https://timleland.com/when-did-you-last-write-code/
Comments URL: https://news.ycombinator.com/item?id=49917571
Points: 3
# Comments: 0
What is going on with ceiling fans
Article URL: https://mcmansionhell.com/post/829127919552151552/what-is-going-on-with-ceiling-fans
Comments URL: https://news.ycombinator.com/item?id=49917536
Points: 3
# Comments: 0
What managing emergencies at Burning Man teaches about tech incident management
Article URL: https://greatcircle.com/blog/2026/09/29/burning-man-incident-management/
Comments URL: https://news.ycombinator.com/item?id=49917534
Points: 3
# Comments: 0
Google Grapples with Employee Skepticism About New Gemini Model
Article URL: https://finance.yahoo.com/technology/ai/articles/google-grapples-employee-skepticism-gemini-195242680.html
Comments URL: https://news.ycombinator.com/item?id=49917533
Points: 2
# Comments: 0
"Revize., The Government Website Expert"
Article URL: https://www.revize.com/projects/
Comments URL: https://news.ycombinator.com/item?id=49917529
Points: 2
# Comments: 1
AXFeedback – an agent that tests your devtools quickstart on a schedule
Article URL: https://axfeedback.dev
Comments URL: https://news.ycombinator.com/item?id=49917356
Points: 1
# Comments: 0
Operation Rubicon
Article URL: https://en.wikipedia.org/wiki/Operation_Rubicon
Comments URL: https://news.ycombinator.com/item?id=49917343
Points: 1
# Comments: 0
Stanislaw Lem quote related to LLMs
A man can control only what he comprehends, and comprehend only what he is able to put into words. The inexpressible therefore is unknowable. -- Stanislaw Lem "The Futurology Congress"
This is certainly interesting in LLM land :-)
Comments URL: https://news.ycombinator.com/item?id=49917321
Points: 1
# Comments: 0
Second judge blocks $100k fee for new H-1B worker visas
Central Casting
Article URL: https://en.wiktionary.org/wiki/central_casting
Comments URL: https://news.ycombinator.com/item?id=49917295
Points: 1
# Comments: 0
Parsing compressed JSON at 40 GB/s
Article URL: https://lemire.me/blog/2026/10/01/parsing-compressed-json-at-40-gb-s/
Comments URL: https://news.ycombinator.com/item?id=49917280
Points: 1
# Comments: 0
Hundreds Detained in France as Some Student Protests Turn Violent
Article URL: https://www.nytimes.com/2026/09/30/world/europe/france-student-protest-arrests.html
Comments URL: https://news.ycombinator.com/item?id=49917253
Points: 2
# Comments: 1
Project management that is fast, privacy-first and flexible, ... powered by Lisp
Article URL: https://codeberg.org/jjba23/lucidplan
Comments URL: https://news.ycombinator.com/item?id=49917248
Points: 1
# Comments: 1
Can Your Identity Platform Pass the Black Friday Test?
Article URL: https://fusionauth.io/blog/black-friday-identity-test
Comments URL: https://news.ycombinator.com/item?id=49917228
Points: 1
# Comments: 0
Agents are choosing the software infrastructure now, and we're not ready
Article URL: https://redmonk.com/jgovernor/agents-are-choosing-the-software-infrastructure-now-and-were-not-really-ready/
Comments URL: https://news.ycombinator.com/item?id=49917220
Points: 1
# Comments: 0
Polytoken is a local-first AI coding agent daemon
Article URL: https://docs.polytoken.dev/introduction/
Comments URL: https://news.ycombinator.com/item?id=49917210
Points: 1
# Comments: 0
The Invention of Islamic Invention
Article URL: https://www.cremieux.xyz/p/the-invention-of-islamic-invention
Comments URL: https://news.ycombinator.com/item?id=49917150
Points: 2
# Comments: 0
Show HN: BlindFlag – Double-blind dealbreaker test via client-side PSI
Article URL: https://blindflag.com
Comments URL: https://news.ycombinator.com/item?id=49917127
Points: 1
# Comments: 0
