Skip to content

Fix Typo in logical operators#1894

Merged
iliakan merged 1 commit intojavascript-tutorial:masterfrom
mkawi:patch-1
May 17, 2020
Merged

Fix Typo in logical operators#1894
iliakan merged 1 commit intojavascript-tutorial:masterfrom
mkawi:patch-1

Conversation

@mkawi
Copy link
Contributor

@mkawi mkawi commented May 8, 2020

true || alert("printed")
false || alert("not printed") 

This is confusing as the first won't be printed, but the second will print "not printed". I've reversed it so it makes more sense:

true || alert("not printed")
false || alert("printed")

true || alert("printed")
false || alert("not printed") 

This is confusing to a student as the first won't be printed, but the second will print "not printed". I've reversed it to this so it makes much more sense to a learner:

true || alert("not printed")
false || alert("printed")
@CLAassistant
Copy link

CLAassistant commented May 8, 2020

CLA assistant check
All committers have signed the CLA.

@iliakan iliakan merged commit 9353a04 into javascript-tutorial:master May 17, 2020
@mkawi mkawi deleted the patch-1 branch May 17, 2020 21:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments