3 ms·
I was interested how are they doing the "IQ estimation", here it is: -(dogPos + Math.abs(menPos - womenPos) + Math.abs(whiteNegative - nonWhiteNegative) + k
by 1023bytes 7y ago
I was interested how are they doing the "IQ estimation", here it is:
-(dogPos + Math.abs(menPos - womenPos) + Math.abs(whiteNegative - nonWhiteNegative) + kanyePos)
- qqii 7y agoAfter seeing no code in their repo I was interested in the same. The important parts are in https://stealingurfeelin.gs/js/events.min.js https://stealingurfeelin.gs/js/events.min.js You've left out some important parts of the iq calculation, with the full equation being: reactions = dogPos + Math.abs(menPos - womenPos) + Math.abs(whiteNegative - nonWhiteNegative) + kanyePos) / 4; iq = Math.floor(15 * -((reactions - 0.0005) / 0.05) + 100); if (iq < 100) { thatPartBitSFX.play() } else { thatPartWaySFX.play() } Also amusingly rebulican percentage is calculated as: reactions = (dogPos + kanyePos + nonWhiteNegative) / 3; republicanPct = 50 + 15 * ((reactions - 0.05) / 0.1), And income is calculated as: reactions = (iq / 100 + republicanPct / 50 + dogPos) / 3 estimatedIncome = Math.floor(200000 * (reactions - 0.5) + 31099), if (estimatedIncome < 31099) { isPoorSFX.play() } else { isNotPoorSFX.play() }
- PastaMonster 7y agoOh dear. Lots of magic numbers. The programmers are not educated properly. Just horrible code.
- spiznnx 7y agoNNs are full of magic numbers that were learned from training sets.
- testvox 7y agoThis is minified code, so couldn't the minifier have replaced the constants with their values or something?
- 9935c101ab17a66 7y agoThose aren't minified or obfuscated variable names... that's obvious.
- deleted 7y ago[deleted]
- Cthulhu_ 7y agoA minifier is actually more likely to introduce constants for repeated values.
- nl 7y agoI think you are missing the point. The horrible magic numbers are outrageous because of the arbitrary nature of them. And for those of us who read the code we are supposed to notice that. Hiding them behind constants would lessen the impact of that.
- newen 7y agoIt's supposed to be funny
- fouc 7y agoThe math here is saying you're poor if you're a low-IQ democrat, and not poor otherwise.
- grenoire 7y agoDon't forget about dog love.
- WrtCdEvrydy 7y agoYeah, I was wondering that one...