4 ms·
Come on, really? "Knowing the very basics of binary numbers" isn't some obscure super-technical skill when it comes to programming, it's fairly fundamental. If
by OskarS 8y ago
Come on, really? "Knowing the very basics of binary numbers" isn't some obscure super-technical skill when it comes to programming, it's fairly fundamental. If they don't know that, then how can they possibly know how to use bit-masks, for instance?
Like, I get it when people say "most of the stuff you learn getting a CS degree has very limited usefulness day to day". Sure, you're not going to be implementing red-black trees or skip lists in your day-to-day, but you can't possibly claim that having a basic idea of how the bitwise operators work (or the details on how numbers are represented in binary) is in the same category.
- juliangoldsmith 8y ago>how can they possibly know how to use bit-masks, for instance? Given that most programming jobs are web development jobs (I think, I don't have numbers to back that up), what makes using bit-masks important? That is, why would someone working on a web application need to know how to use them?
- phaemon 8y agoSo that they understand how a network mask works? I'm assuming if you're working on the web you ought to know something about networks, right?
- juliangoldsmith 8y agoWhy would a regular web developer need to know anything about network masks? Those come up in administration, but generally not in development.
- tonyarkles 8y agoI might be asking a bit much here, but I generally expect someone who's developing something that's going to run on the Internet to have some understanding of how the Internet works. Like... you don't need to understand the intricacies of BGP, but some idea of how a request from your web browser leaves your home network and comes back is strongly appreciated. My biggest reasoning for desiring that skill is debugging. If you build a system and it doesn't work right for whatever reason, it's good to understand why that might be. Also, having some appreciation for that stuff really helps you make good decisions (but why can't I make 200 HTTP requests while loading my page?!)
- dahfizz 8y agoMost programmers nowadays just write frontend javascript and have no idea how anything actually works.
- frockington 8y agoIn my career I have never had to know any binary number. I am on the application side of things though and try to void working with infrastructure at all so don't know about them
- sidlls 8y agoThere are relatively few programming jobs that actually require bit manipulation at that level. I've been deep into bit manipulation twice in my career (well more than 10 years now): network programming for a real time system and game development. For the machine learning and infrastructure work I've done the last 5 years or so I haven't had to do even a single bitmask, shift, etc. directly. Of course we use these things liberally (e.g. hash functions) but it's hardly necessary to write the code itself very often, even in very sophisticated applications.
- slededit 8y agoProgramming used to be mostly bit twiddling. The universe has expanded considerably, but if your still in that original corner its really hard to not see it as a basic skill. Javascript only has doubles so you can't even bit twiddle if you wanted - C programmers can't even imagine.
- walljm 8y agoJavascript stores integers in twos complement
- slededit 8y ago> JavaScript numbers are always stored as double precision floating point numbers, following the international IEEE 754 standard. It doesn't have integers to store. https://www.w3schools.com/js/js_numbers.asp https://www.w3schools.com/js/js_numbers.asp
- tripletao 8y agoThat quote describes a good mental model for someone learning JavaScript, but not necessarily the physical truth. JavaScript's numbers can do everything doubles can; but if the compiler can prove that all values that a particular variable could possibly take on will fit in a smaller type, then it can use that. So a variable really can end up stored as an integer--or never stored anywhere for that matter, like if a loop gets unrolled and the counter is optimized out. The bitwise operators behave as if integers are 32-bit two's complement. The typed arrays are also two's complement. A smart developer can write code that a smart compiler will compile to bitwise operations on actual physical 32-bit integers. https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Bitwise_Operators https://developer.mozilla.org/en-US/docs/Web/JavaScript/Refe... https://v8project.blogspot.com/2017/09/elements-kinds-in-v8.html https://v8project.blogspot.com/2017/09/elements-kinds-in-v8....