Uncovering Hidden Gems in JavaScript Subham Behera on July 05, 2024 JavaScript is one of the most versatile and widely used programming languages in the world. It powers everything from simple websites to complex we... Read full post Submit Preview Dismiss Collapse Expand Jon Randy 🎖️ Jon Randy 🎖️ Jon Randy 🎖️ Follow 🤖 Artisanal developer - coding with varying degrees of success since 1983 Location Bangkok 🇹🇭 Joined Jun 1, 2018 • Jul 5 '24 Dropdown menu Copy link Hide The !! Double Bang Operator There is no such operator, you are simply using the logical not (!) operator twice. Collapse Expand Adam Winters Adam Winters Adam Winters Follow Joined Jul 5, 2024 • Jul 5 '24 Dropdown menu Copy link Hide I would have highly suggested googling the double bang operator, before you responded saying there is no such thing... Collapse Expand Jon Randy 🎖️ Jon Randy 🎖️ Jon Randy 🎖️ Follow 🤖 Artisanal developer - coding with varying degrees of success since 1983 Location Bangkok 🇹🇭 Joined Jun 1, 2018 • Jul 6 '24 Dropdown menu Copy link Hide Could you point out to me where in the list of unary operators in the official language specification it appears? tc39.es/ecma262/#sec-unary-operators Adam Winters Adam Winters Adam Winters Follow Joined Jul 5, 2024 • Jul 6 '24 Dropdown menu Copy link Hide Ahh okay I misread what you said, sorry. It's technically not its own operator, just a combination of 2 logical nots. However, it is widely known as the double bang operator so I wouldn't go as far as saying "there's no such operator". Jon Randy 🎖️ Jon Randy 🎖️ Jon Randy 🎖️ Follow 🤖 Artisanal developer - coding with varying degrees of success since 1983 Location Bangkok 🇹🇭 Joined Jun 1, 2018 • Jul 6 '24 Dropdown menu Copy link Hide I would, as it creates a misunderstanding of the language and what's going on Adam Winters Adam Winters Adam Winters Follow Joined Jul 5, 2024 • Jul 6 '24 Dropdown menu Copy link Hide I mean, the += operator isn't in the list of unary operators, but it's still widely used and known as a JavaScript operator. He also never stated that !! was a unary operator. Collapse Expand Deepak Vishwakarma Deepak Vishwakarma Deepak Vishwakarma Follow Joined Aug 8, 2024 • Aug 9 '24 Dropdown menu Copy link Hide @jonrandy Such cool post Code of Conduct • Report abuse
There is no such operator, you are simply using the logical not (
!) operator twice.I would have highly suggested googling the double bang operator, before you responded saying there is no such thing...
Could you point out to me where in the list of unary operators in the official language specification it appears?
tc39.es/ecma262/#sec-unary-operators
Ahh okay I misread what you said, sorry. It's technically not its own operator, just a combination of 2 logical nots.
However, it is widely known as the double bang operator so I wouldn't go as far as saying "there's no such operator".
I would, as it creates a misunderstanding of the language and what's going on
I mean, the += operator isn't in the list of unary operators, but it's still widely used and known as a JavaScript operator.
He also never stated that !! was a unary operator.
@jonrandy Such cool post