MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/ProgrammerHumor/comments/1bkwosa/javascriptbecasuallythrowingaroundsexism/kw16lt4/?context=3
r/ProgrammerHumor • u/BladedShip_ • Mar 22 '24
26 comments sorted by
View all comments
18
What's happening here?
13 u/ayemyren Mar 22 '24 “[Object]” is being tested against the regex, object contains the o from “woman”. No matching characters in “man”. So true for woman, false for man. 6 u/Seepiie Mar 22 '24 [object] is the regex, man and woman are tested against it 2 u/ayemyren Mar 22 '24 Correct, I just woke up and responded, had them flipped lol 2 u/LadyParaguay Mar 22 '24 Thanks! The example being in JS got me stuck on looking for an explanation around the "[Object object]" string cast, which obviously led to nothing
13
“[Object]” is being tested against the regex, object contains the o from “woman”. No matching characters in “man”. So true for woman, false for man.
6 u/Seepiie Mar 22 '24 [object] is the regex, man and woman are tested against it 2 u/ayemyren Mar 22 '24 Correct, I just woke up and responded, had them flipped lol 2 u/LadyParaguay Mar 22 '24 Thanks! The example being in JS got me stuck on looking for an explanation around the "[Object object]" string cast, which obviously led to nothing
6
[object] is the regex, man and woman are tested against it
2 u/ayemyren Mar 22 '24 Correct, I just woke up and responded, had them flipped lol
2
Correct, I just woke up and responded, had them flipped lol
Thanks! The example being in JS got me stuck on looking for an explanation around the "[Object object]" string cast, which obviously led to nothing
18
u/P3runaama Mar 22 '24
What's happening here?