Has anyone else avoided a programming language because it’s “too mainstream” for them?
Does anyone read programming books? Like actually?
Keeping them on a shelf having skimmed the table of contents doesn’t count.
Question for a higher power: Is the ability to access specific list indices something I’ve always taken for granted? Or should it be an expectation?
Scheme’s implementation of a “list” is a series of nested pairs (sorta nested - I’m calling it that even though that’s not completely correct), so you can either get the first element in the list or all of the others UNLESS you know the specific index you need in a constant fashion (i.e. “c” + [combination of “a”s and “d”s] + “r”).
Haskell has those sweet sweet index accessors we all know and love from C and it’s children and even most of it’s counterparts. Even in C itself there was functionality to store an address to a pointer and then just do pointer arithmetic to access an index like arr[2] -> 0x#{ADDRESS OF arr} + 2. It’s simple and straightforward, so I don’t feel like I’m being difficult to expect that of my programming language. Am I, though?
You’ve probably noticed by now that this post isn’t meant to be a coherent case for anything; it’s more of a ramble and a rant. Honestly, though, just give me accessors (and mutatability too please... I’m looking at you Go. Nobody thinks you’re slick with your whole “arrays are static and annoying use slices because we’re edgy”).
I continue to be surprised today. Haskell is also cool, at least based on what I’m reading. I haven’t written any yet, though, so we’ll see.
Maybe I’m just in an open mood. Should I break out the old assembly docs and test that theory?
.... Nah, I definitely shouldn’t do that.
Making a favicon for your website is one of the simple pleasures.
Want to go on record and say that the owner of this blog did, in fact, read dracula daily. Time and time again I tried to think of fun ways to relate it to programming. Yet time and time again I couldn’t bring myself to do it.
Not because there weren’t ways I could shoehorn in a weird analogy, but because I admired the characters too much to force one. Idk it just felt disrespectful to bring code into this.
Will happily disrespect Dracula, though. Got some real cobol energy from that dinosaur. Particularly the way he drains the life out of a lot of happy, wonderful people.
Django actually has a built-in tag specifically for generating the latin gibberish used in samples. They already solved every real problem for developers, so they proceeded to solve problems you didn’t even know you wanted solved.
I have so much respect for the ToString() method of Pandas Dataframes in Python.
If you’re wondering why, it’s because I’m currently trying to make a halfway decent depiction of a C# matrix multidimensional array that just puts my hashkeys in the right places and things are not going well at all.
An epistle on an “oh duh” moment I just had while pondering switch functionality in Python.
Every couple of months when I get back into some hobbyist Python development I find myself DuckDuckGo-ing “switch in Python” and am subsequently always reminded that that’s not explicitly a thing. You, of course, get that functionality from dictionaries.
I’ve always thought that was dumb, but today I was considering it and realized that it’s all because of the interpreted nature of the language. Switch statements have the wicked performance improvements over if ladders in compiled languages because the switch tells the compiler to put a bunch of branches in the intermediate assembly so a lot of unnecessary condition checks are skipped.
Without in-depth knowledge of how the interpreter works, it now becomes clear why you have to use the dictionary. It’s not the Python lords being pretentious and imposing their pythonic ways; you have to be more explicit to the interpreter about where to look for the logic to run because the interpreter doesn’t craft intermediate assembly, it just plows straight through. So a switch in Python would ultimately perform no better than an if ladder.
That doesn’t mean a switch wouldn’t make me happy, mind you.
Guess who jumped into his first React project without any planning and now continues to add features thereby creating a monstrosity of spaghetti code. THIS guy!
he/himComplaining on Tumblr is a good alternative to punching my computer screen, right?
72 posts