New

The latest blog posts to take off on Hacker News. 3,709 posts.

Any topic
2026
2285

WASM is not quite a stack machine

Everyone knows Wasm is a stack machine. Wikipedia says so, the official Wasm design specification says so, you get it. I thought so too. That is, until I started writing Wasm code – not compiling for Wasm, but writing the instructions by hand. And I found out that there exists a major difference between Wasm and all…

2290

You can beat the binary search

We sometimes have to look for a value in a sorted array. The simplest algorithm consists in just going through the values We sometimes have to look for a value in a sorted array. The simplest algorithm consists in just going through the values one by one, until we encounter the value, or exhaust the … Continue reading…

2292

The woes of sanitizing SVGs

Scratch has a long history of SVG-related vulnerabilities. The source of these is that Scratch parses user-generated (ie. attacker-controlled) content into an <svg> element and appends it into the main document for various operations (eg. measuring SVG bounding box in a more reliable way than viewbox or width/height).

2294

Men who stare at walls

I came across a video by Simple Lucas describing a routine to improve focus and productivity. The routine was basically: Don’t use any screens/entertainment when trying to focus on work. When you start to feel mentally drained, sit and stare at a wall for x minutes to recover focus. I’ve been trying it, and it’s a…