From 1c5e651c51ac9fd4f459ad3f590ff5666f0daeb6 Mon Sep 17 00:00:00 2001 From: joaquinelio Date: Wed, 11 Jun 2025 16:38:57 -0300 Subject: [PATCH 1/2] truthy link --- 1-js/02-first-steps/10-ifelse/article.md | 2 +- 1-js/02-first-steps/11-logical-operators/article.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/1-js/02-first-steps/10-ifelse/article.md b/1-js/02-first-steps/10-ifelse/article.md index 82e8800b9c..2fa9276ddb 100644 --- a/1-js/02-first-steps/10-ifelse/article.md +++ b/1-js/02-first-steps/10-ifelse/article.md @@ -31,7 +31,7 @@ if (year == 2015) { We recommend wrapping your code block with curly braces `{}` every time you use an `if` statement, even if there is only one statement to execute. Doing so improves readability. -## Boolean conversion +## Boolean conversion [#ifelse-boolean-conversion] The `if (…)` statement evaluates the expression in its parentheses and converts the result to a boolean. diff --git a/1-js/02-first-steps/11-logical-operators/article.md b/1-js/02-first-steps/11-logical-operators/article.md index 78c4fd2f1b..d9ca4b044e 100644 --- a/1-js/02-first-steps/11-logical-operators/article.md +++ b/1-js/02-first-steps/11-logical-operators/article.md @@ -29,7 +29,7 @@ alert( false || false ); // false As we can see, the result is always `true` except for the case when both operands are `false`. -If an operand is not a boolean, it's converted to a boolean for the evaluation. +If an operand is not a boolean, it's converted to a boolean for the evaluation. This is part of the familiar truthy/falsy concept . For instance, the number `1` is treated as `true`, the number `0` as `false`: From b3bb7c3fa5bd1e962d6f422fc1728c9b6bb0b509 Mon Sep 17 00:00:00 2001 From: joaquinelio Date: Wed, 11 Jun 2025 17:42:29 -0300 Subject: [PATCH 2/2] info link fix --- 1-js/02-first-steps/10-ifelse/article.md | 2 +- 1-js/02-first-steps/11-logical-operators/article.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/1-js/02-first-steps/10-ifelse/article.md b/1-js/02-first-steps/10-ifelse/article.md index 2fa9276ddb..4995648a3a 100644 --- a/1-js/02-first-steps/10-ifelse/article.md +++ b/1-js/02-first-steps/10-ifelse/article.md @@ -31,7 +31,7 @@ if (year == 2015) { We recommend wrapping your code block with curly braces `{}` every time you use an `if` statement, even if there is only one statement to execute. Doing so improves readability. -## Boolean conversion [#ifelse-boolean-conversion] +## Boolean conversion [#boolean-conversion] The `if (…)` statement evaluates the expression in its parentheses and converts the result to a boolean. diff --git a/1-js/02-first-steps/11-logical-operators/article.md b/1-js/02-first-steps/11-logical-operators/article.md index d9ca4b044e..d4b07cfa1b 100644 --- a/1-js/02-first-steps/11-logical-operators/article.md +++ b/1-js/02-first-steps/11-logical-operators/article.md @@ -29,7 +29,7 @@ alert( false || false ); // false As we can see, the result is always `true` except for the case when both operands are `false`. -If an operand is not a boolean, it's converted to a boolean for the evaluation. This is part of the familiar truthy/falsy concept . +If an operand is not a boolean, it's converted to a boolean for the evaluation. This is part of the familiar [truthy/falsy](info:ifelse#boolean-conversion) concept. For instance, the number `1` is treated as `true`, the number `0` as `false`: