#weirdjavascript kết quả tìm kiếm
Dealing with float number instead of integers could break your code. I just thought why not I should change 11/10 to 1.1 in the code. And it goes weird #javascript #weirdJavascript

When "2" + "2" is calculated, they are string so concat happens and "22" is the result. Followed by "22" - "2" where "-" is use for subtraction and strings are type casted into integers which results in 20. #javascript #weird #weirdjavascript

So I was bored and found this video in my recommended: youtube.com/watch?v=sRWE5t…. And decided to give it a try myself. So I did, with a lot of explanation because I was bored: github.com/ProfessorQu/js… #javascript #weirdjavascript
youtube.com
YouTube
JavaScript Is Weird (EXTREME EDITION)
Weird JavaScript 😂🤪 console.log(NaN === NaN); // prints false #javascript #weirdjavascript @JavaScript @JavaScriptDaily
#weirdJavascript “JavaScript — The weird parts” by @daffl medium.com/@daffl/javascr…
Weird JavaScript 😂🤪 let iAmNumber = 1; if (iAmNumber === 1) { console.log(iAmNumber); // Prints ReferenceError let iAmNumber = 2; } @JavaScript @JavaScriptDaily #javascript #weirdjavascript
Yeah! YOU Should...It is indeed a good practice as it somehow enhances the readability of the code. Point Of Termination Right! If You Know You Know ✌️ #javascript #weirdjavascript
Weird JavaScript 😂🤪 const a = (1, b = 2); console.log(a); // prints 2 console.log(b); // prints 2 @JavaScript @JavaScriptDaily #javascript #weirdjavascript
Forgot to add tags to help the thread spread. I welcome all logic why this was valid in usage but not as direct variable declaration. #javascript #weirdJavascript #observation #React #Json #techtwitter #techDiscussion #tech #sharing
Weird JavaScript 😂🤪 let infinity = 1/0; console.log(infinity); // prints Infinity console.log(typeof infinity); //prints number console.log(typeof 1/0); //prints NaN #javascript #weirdjavascript @JavaScript @JavaScriptDaily
Weird JavaScript 😂🤪 let num1 = 2; let num2 = 4; const sum = 'num1 + num2'; // Prints 6 console.log(eval(sum)); const iAmEval = eval; // ReferenceError: num1 is not defined. console.log(iAmEvalFunction(sum)); @JavaScript @JavaScriptDaily #javascript #weirdjavascript
Why [’1’, ’7’, ’11’].map(parseInt) returns [1, NaN, 3] in Javascript by @erictongs link.medium.com/iYu53IMwQ5 #weirdjavascript #100daysofcode
Yeah! YOU Should...It is indeed a good practice as it somehow enhances the readability of the code. Point Of Termination Right! If You Know You Know ✌️ #javascript #weirdjavascript
So I was bored and found this video in my recommended: youtube.com/watch?v=sRWE5t…. And decided to give it a try myself. So I did, with a lot of explanation because I was bored: github.com/ProfessorQu/js… #javascript #weirdjavascript
youtube.com
YouTube
JavaScript Is Weird (EXTREME EDITION)
Weird JavaScript 😂🤪 let num1 = 2; let num2 = 4; const sum = 'num1 + num2'; // Prints 6 console.log(eval(sum)); const iAmEval = eval; // ReferenceError: num1 is not defined. console.log(iAmEvalFunction(sum)); @JavaScript @JavaScriptDaily #javascript #weirdjavascript
Weird JavaScript 😂🤪 const a = (1, b = 2); console.log(a); // prints 2 console.log(b); // prints 2 @JavaScript @JavaScriptDaily #javascript #weirdjavascript
Weird JavaScript 😂🤪 let iAmNumber = 1; if (iAmNumber === 1) { console.log(iAmNumber); // Prints ReferenceError let iAmNumber = 2; } @JavaScript @JavaScriptDaily #javascript #weirdjavascript
Weird JavaScript 😂🤪 console.log(NaN === NaN); // prints false #javascript #weirdjavascript @JavaScript @JavaScriptDaily
Weird JavaScript 😂🤪 let infinity = 1/0; console.log(infinity); // prints Infinity console.log(typeof infinity); //prints number console.log(typeof 1/0); //prints NaN #javascript #weirdjavascript @JavaScript @JavaScriptDaily
Forgot to add tags to help the thread spread. I welcome all logic why this was valid in usage but not as direct variable declaration. #javascript #weirdJavascript #observation #React #Json #techtwitter #techDiscussion #tech #sharing
When "2" + "2" is calculated, they are string so concat happens and "22" is the result. Followed by "22" - "2" where "-" is use for subtraction and strings are type casted into integers which results in 20. #javascript #weird #weirdjavascript

Why [’1’, ’7’, ’11’].map(parseInt) returns [1, NaN, 3] in Javascript by @erictongs link.medium.com/iYu53IMwQ5 #weirdjavascript #100daysofcode
‘BANANA’ with JavaScript by @MahdhiRezvi link.medium.com/2IizsaYyc2 What are your personal WTF moments of JavaScript? Feel free to comment :D #javascript #js #weirdjavascript #ilovejavascript #programming #happycoding
Dealing with float number instead of integers could break your code. I just thought why not I should change 11/10 to 1.1 in the code. And it goes weird #javascript #weirdJavascript

#weirdJavascript “JavaScript — The weird parts” by @daffl medium.com/@daffl/javascr…
Dealing with float number instead of integers could break your code. I just thought why not I should change 11/10 to 1.1 in the code. And it goes weird #javascript #weirdJavascript

When "2" + "2" is calculated, they are string so concat happens and "22" is the result. Followed by "22" - "2" where "-" is use for subtraction and strings are type casted into integers which results in 20. #javascript #weird #weirdjavascript

Something went wrong.
Something went wrong.
United States Trends
- 1. White House 441K posts
- 2. ChatGPT Atlas 3,939 posts
- 3. Fermin 32.2K posts
- 4. Kurt Suzuki 1,688 posts
- 5. #pilotstwtselfieday 1,084 posts
- 6. Crosby 4,465 posts
- 7. NASA 63.9K posts
- 8. Woody Johnson N/A
- 9. Rick Scott 2,132 posts
- 10. John Brennan 8,586 posts
- 11. #TrumpHatesOurHealthCare 2,903 posts
- 12. Olympiacos 28.1K posts
- 13. #Integra 1,145 posts
- 14. Warner Bros 7,838 posts
- 15. #JUNGKOOKXCALVINKLEIN 56.2K posts
- 16. NBA IS BACK 29K posts
- 17. East Wing 111K posts
- 18. #3YearsOfMidnights 1,152 posts
- 19. Taco Tuesday 14.7K posts
- 20. Uribe 136K posts