From fc04896d8fa6ebdbd2c3df667a2848f10980626c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Enrique=20S=C3=A1nchez?= <24756926+enriqueesanchz@users.noreply.github.com> Date: Mon, 20 May 2024 23:48:18 +0200 Subject: [PATCH] ratio division error --- content/english/hpc/arithmetic/float.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/content/english/hpc/arithmetic/float.md b/content/english/hpc/arithmetic/float.md index dcc33039..20e18fe9 100644 --- a/content/english/hpc/arithmetic/float.md +++ b/content/english/hpc/arithmetic/float.md @@ -38,7 +38,7 @@ struct r { r operator+(r a, r b) { return {a.x * b.y + a.y * b.x, a.y * b.y}; } r operator*(r a, r b) { return {a.x * b.x, a.y * b.y}; } -r operator/(r a, r b) { return {a.x * b.x, a.y * b.y}; } +r operator/(r a, r b) { return {a.x * b.y, a.y * b.x}; } bool operator<(r a, r b) { return a.x * b.y < b.x * a.y; } // ...and so on, you get the idea ```