From e689ac951b01923969cdab958114e5099db81169 Mon Sep 17 00:00:00 2001 From: Freek Van der Herten Date: Mon, 9 Feb 2026 21:03:52 +0100 Subject: [PATCH] Fix incorrect less-than examples and improve greater-than examples Less-than: `2 < '3'` and `2 < 3.0` both evaluate to `true`, not `false`. Greater-than: changed examples to use `3 > '2'` and `3 > 2.0` (both `true`) to better demonstrate cross-type comparisons. Fixes #32 Co-Authored-By: Claude Opus 4.6 --- resources/content/comparison-06-less-than.md | 4 ++-- resources/content/comparison-07-greater-than.md | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/resources/content/comparison-06-less-than.md b/resources/content/comparison-06-less-than.md index 51bdc51..3c410ad 100644 --- a/resources/content/comparison-06-less-than.md +++ b/resources/content/comparison-06-less-than.md @@ -10,6 +10,6 @@ Check if the value to the left is less than the value to the right. ```php 2 < 3; // true -2 < '3'; // false -2 < 3.0; // false +2 < '3'; // true +2 < 3.0; // true ``` diff --git a/resources/content/comparison-07-greater-than.md b/resources/content/comparison-07-greater-than.md index 29a30a5..4ab3153 100644 --- a/resources/content/comparison-07-greater-than.md +++ b/resources/content/comparison-07-greater-than.md @@ -10,6 +10,6 @@ Check if the value to the left is greater than the value to the right. ```php 3 > 2; // true -2 > '2'; // false -2 > 2.0; // false +3 > '2'; // true +3 > 2.0; // true ```