frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

The Peaceful Transfer of Power in Open Source Projects

https://shkspr.mobi/blog/2025/11/the-peaceful-transfer-of-power-in-open-source-projects/
98•edent•2h ago•53 comments

Emoji Evidence Errors Don't Undo a Murder Conviction–People vs. Harmon

https://blog.ericgoldman.org/archives/2025/11/emoji-evidence-errors-dont-undo-a-murder-conviction...
13•hn_acker•20m ago•1 comments

Launch HN: Mosaic (YC W25) – Agentic Video Editing

https://mosaic.so
10•adishj•38m ago•0 comments

Your Smartphone, Their Rules: App Stores Enable Corporate-Government Censorship

https://www.aclu.org/news/free-speech/app-store-oligopoly
217•pabs3•2h ago•110 comments

Programming the Commodore 64 with .NET

https://retroc64.github.io/
28•mariuz•5d ago•3 comments

Gymkhana's 1978 Subaru Brat with 9,500-RPM Redline, Active Aero Is One Super Ute

https://www.thedrive.com/news/gymkhanas-1978-subaru-brat-with-9500-rpm-redline-and-active-aero-is...
32•PaulHoule•1w ago•29 comments

The $1k AWS Mistake

https://www.geocod.io/code-and-coordinates/2025-11-18-the-1000-aws-mistake/
135•thecodemonkey•6h ago•141 comments

Gemini 3

https://blog.google/products/gemini/gemini-3/
1566•preek•1d ago•982 comments

Multimodal Diffusion Language Models for Thinking-Aware Editing and Generation

https://github.com/tyfeld/MMaDA-Parallel
89•lnyan•6h ago•6 comments

The Future of Programming (2013) [video]

https://www.youtube.com/watch?v=8pTEmbeENF4
84•jackdoe•6d ago•48 comments

I made a down detector for down detector

https://downdetectorsdowndetector.com
384•gusowen•16h ago•122 comments

How to Stay Sane in a World That Rewards Insanity

https://www.joanwestenberg.com/p/how-to-stay-sane-in-a-world-that-rewards-insanity
55•enbywithunix•1h ago•25 comments

Proxmox Virtual Environment 9.1 available

https://www.proxmox.com/en/about/company-details/press-releases/proxmox-virtual-environment-9-1
49•speckx•1h ago•30 comments

Google Antigravity

https://antigravity.google/
984•Fysi•1d ago•959 comments

I just want working RCS messaging

https://wt.gd/i-just-want-my-rcs-messaging-to-work
197•joecool1029•14h ago•191 comments

Pimped Amiga 500

https://www.pimyretro.org/pimped-amiga-500/
68•onename•4h ago•28 comments

Europe is scaling back its landmark privacy and AI laws

https://www.theverge.com/news/823750/european-union-ai-act-gdpr-changes
34•ksec•1h ago•16 comments

Pebble, Rebble, and a path forward

https://ericmigi.com/blog/pebble-rebble-and-a-path-forward/
439•phoronixrly•22h ago•225 comments

Show HN: Browser-based interactive 3D Three-Body problem simulator

https://trisolarchaos.com/?pr=O_8(0.6)&n=3&s=5.0&so=0.00&im=rk4&dt=1.00e-4&rt=1.0e-6&at=1.0e-8&bs...
188•jgchaos•1d ago•74 comments

Ultima VII Revisited

https://github.com/ViridianGames/U7Revisited
169•erickhill•1w ago•50 comments

Itiner-e: A high-resolution dataset of roads of the Roman Empire

https://www.nature.com/articles/s41597-025-06140-z
20•benbreen•1w ago•4 comments

Learning to Boot from PXE

https://blog.imraniqbal.org/learning-to-boot-from-pxe/
17•speckx•4h ago•11 comments

Blender 5.0

https://www.blender.org/download/releases/5-0/
910•FrostKiwi•18h ago•292 comments

I wrote a Pong game in a 512-byte boot sector

https://akshatjoshi.com/i-wrote-a-pong-game-in-a-512-byte-boot-sector/
76•akshat666•4d ago•13 comments

Cloudflare outage on November 18, 2025 post mortem

https://blog.cloudflare.com/18-november-2025-outage/
1326•eastdakota•16h ago•781 comments

Gemini 3 Pro Model Card [pdf]

https://storage.googleapis.com/deepmind-media/Model-Cards/Gemini-3-Pro-Model-Card.pdf
252•virgildotcodes•1d ago•324 comments

The code and open-source tools I used to produce a science fiction anthology

https://compellingsciencefiction.com/posts/the-code-and-open-source-tools-i-used-to-produce-a-sci...
181•mojoe•23h ago•30 comments

Mojo-V: Secret Computation for RISC-V

https://github.com/toddmaustin/mojo-v
48•fork-bomber•1w ago•15 comments

Cloudflare Global Network experiencing issues

https://www.cloudflarestatus.com/incidents/8gmgl950y3h7
2397•imdsm•1d ago•1620 comments

I made a downdetector for downdetector's downdetector's downdetector

https://downdetectorsdowndetectorsdowndetectorsdowndetector.com
70•halgir•6h ago•12 comments
Open in hackernews

Comparing floating-point numbers (2012)

https://randomascii.wordpress.com/2012/02/25/comparing-floating-point-numbers-2012-edition/
26•sph•6mo ago

Comments

LegionMammal978•6mo ago
I'd argue that any equality comparison of floating-point numbers is asking for trouble, unless you're specifically working with small dyadic fractions (using exact comparison) or testing a purely heuristic 'closeness' condition (using fuzzy comparison).

Of course, inequalities show up in a lot more places, but are similarly fraught with difficulty, since mathematical statements may fail to translate to floating-point inequalities. E.g., in computational geometry, people have written entire papers about optimizing correct orientation predicates [0], since the naive method can easily break at small angles. This sort of thing is what often shows up as tiny seams in 3D video-game geometry.

[0] https://www.cs.cmu.edu/~quake/robust.html

mtklein•6mo ago
My preferred way to compare floats as being interchangeably equivalent in unit tests is

    bool equiv(float x, float y) {
        return (x <= y && y <= x)
            || (x != x && y != y);
    }
This handles things like ±0 and NaNs (while NaNs can't be IEEE-754-equal per se, they're almost always interchangeable), and convinces -Wfloat-equal you kinda know what you're doing. Also everything visually lines up real neat and tidy, which I find makes it easy to remember.

Outside unit tests... I haven't really encountered many places where float equality is actually what I want to test. It's usually some < or <= condition instead.

sph•6mo ago
I have built a production Javascript library with decent amounts of users that incorporates the following hack to deal with float error (avert your eyes if you're sensitive):

  // 1.2 - 1.0 === 0.19999999999999996
  // fixFloatError(1.2 - 1.0) === 0.2
  var fixFloatError = function (n) {
    return parseFloat(n.toPrecision(12));
  };
It felt correct at the time, but after reading the article, I cringe at how fundamentally broken it is. I got away with it because the library is used to convert betting odds, which are mostly small floating point numbers, so the error is often < 10^-12.