3 ms·
Why are these "hipster hacks"? They're really important language features everyone should be using. Side note: has anybody ever had to actually swap variables
by ng12 9y ago
Why are these "hipster hacks"? They're really important language features everyone should be using.
Side note: has anybody ever had to actually swap variables in production code? I thought it was just a fizzbuzz interview question.
- mabynogy 9y ago> has anybody ever had to actually swap variables in production code? I did that today to swap the content of two plain objects without altering the references. It was in Lua but I'll probably to that in JS too tomorrow.
- tal_berzniz 9y agoThe "hipster hacks" are things you not necessarily use but are fun things to try. Some of these are for fun (like #1) and others (like #2) are day to day life-savers. Indeed the swap variables is a fun fact.