Earlier quoted context omitted.
Tangential aside we've collectively made a mistake using A-F for HEX representation. Alphabetical order seemed obvious at the time, but there's a far more literal option that's just pleasing on a visceral level. LHTIFE. The horizontal lines of each letter are literally encoding binary information. True there's no letter encoding 3 in this block style but that can either be invented or ignored. Or you can fudge the pa…
That would be a trivia to have to know, otherwise it just looks like a mess of arbitrarily chosen letters. The binary patterns shown on the chosen letters do not match the actual binary patterns those letters represent. And then you don't try to do the same with 0 to 9 which makes the whole effort half-baked.
Understanding the power of bitwise operators
41–48 of 48 posts
Re: Understanding the power of bitwise operators
#42Earlier quoted context omitted.
Tangential aside we've collectively made a mistake using A-F for HEX representation. Alphabetical order seemed obvious at the time, but there's a far more literal option that's just pleasing on a visceral level. LHTIFE. The horizontal lines of each letter are literally encoding binary information. True there's no letter encoding 3 in this block style but that can either be invented or ignored. Or you can fudge the pa…
The I is a bad choice since it's similar to 1, using the letter Z instead would be much better. The letter T can't be mapped to a 7-segment display either, so if that's your goal you would need to use EFGHLP.
Re: Understanding the power of bitwise operators
#43Earlier quoted context omitted.
> (e.g., Null character (�) a black diamond with white question mark in the middle). The description in the linked article is wrong, that's not a null character (U+0000) or ASCII's NUL. That black diamond symbol is U+FFFD the Unicode Replacement Character, it means "Something went wrong, so instead here is this symbol". For example if your decoder algorithm gets some gibberish and you can't or won't accept errors in…
Tangential aside we've collectively made a mistake using A-F for HEX representation. Alphabetical order seemed obvious at the time, but there's a far more literal option that's just pleasing on a visceral level. LHTIFE. The horizontal lines of each letter are literally encoding binary information. True there's no letter encoding 3 in this block style but that can either be invented or ignored. Or you can fudge the pa…
Re: Understanding the power of bitwise operators
#44Re: Understanding the power of bitwise operators
#45Who is this article for exactly? It starts off by trying to relate to the reader by presenting the point about learning a new programming language, but then goes on to explain one of the most fundamental concepts of computing, as if the reader is a complete novice. I would imagine that nearly every person with programming experience, whether that be formal or not, would have at least some familiarity with binary repr…
In modern programming, bit-banging can usually be avoided. C++ and Rust both have bit fields in structs, and generics for sets of bits. If you're working on some data structure with AND, OR, and shift operations, that's kind of retro today. The compiler is probably better at doing that stuff than you are.
Re: Understanding the power of bitwise operators
#46Is it an autocorrect issue or the writer only-heard-never-read that the "^" character is called a “carrot”?
The "^" character is correctly named the "caret".
Re: Understanding the power of bitwise operators
#47For folks that are interested in learning more about bitwise operations, here is another article (slightly more nuanced) about XORs that you may enjoy reading: All About XOR: https://accu.org/journals/overload/20/109/lewin_1915/
Re: Understanding the power of bitwise operators
#48It's right there in Calculator's menu: View -> Programmer