From 95371f92b3a834b716531b79d651085dfdd17a24 Mon Sep 17 00:00:00 2001 From: jasnkwcz <57577245+jasnkwcz@users.noreply.github.com> Date: Wed, 3 Jun 2020 09:33:03 -0700 Subject: [PATCH] fix(learn): clarify formatting requirements for multiple ternary operators challenge (#38993) * fix(learn): clarify formatting requirements for multiple ternary operators challenge Co-authored-by: Shaun Hamilton <51722130+Sky020@users.noreply.github.com> --- .../use-multiple-conditional-ternary-operators.english.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/curriculum/challenges/english/02-javascript-algorithms-and-data-structures/basic-javascript/use-multiple-conditional-ternary-operators.english.md b/curriculum/challenges/english/02-javascript-algorithms-and-data-structures/basic-javascript/use-multiple-conditional-ternary-operators.english.md index 1bb5c6deff..de9e5e56fc 100644 --- a/curriculum/challenges/english/02-javascript-algorithms-and-data-structures/basic-javascript/use-multiple-conditional-ternary-operators.english.md +++ b/curriculum/challenges/english/02-javascript-algorithms-and-data-structures/basic-javascript/use-multiple-conditional-ternary-operators.english.md @@ -36,7 +36,7 @@ function findGreaterOrEqual(a, b) { } ``` -However, this should be used with care as using multiple conditional operators without proper indentation may make your code hard to read. For example: +It is considered best practice to format multiple conditional operators such that each condition is on a separate line, as shown above. Using multiple conditional operators without proper indentation may make your code hard to read. For example: ```js function findGreaterOrEqual(a, b) { @@ -48,7 +48,7 @@ function findGreaterOrEqual(a, b) { ## Instructions
-Use multiple conditional operators in the checkSign function to check if a number is positive, negative or zero. The function should return "positive", "negative" or "zero". +In the checkSign function, use multiple conditional operators - following the recommended format used in findGreaterOrEqual - to check if a number is positive, negative or zero. The function should return "positive", "negative" or "zero".
## Tests