Some middle-aged guy on the Internet; Seen a lot of it and occasionally regurgitate it, trying to be amusing and informative.

Lurked Digg until v4.

Commented on Reddit (same username) until it went full Musk.

Now I’m here.

Other Adjectives: Neurodivergent; Nerd; Broken; British; Ally; Leftish

Applying for mod in places where an occasional mod would better than none at all.

  • 0 Posts
  • 68 Comments
Joined 1Y ago
cake
Cake day: Jun 12, 2023

help-circle
rss

This has bell curve meme vibes. I’m just not sure what the middle guy would be saying.


Is it still the norm to go to the dev’s office, yank their power cord and when they ask what we’re doing, tell them we’re shipping their machine to the client because it’s the only one that the code runs on?

And can we do that with whatever server ChatGPT-4o is running on?

I’m assuming that this response from 4o isn’t real and was invented for the laugh, but it would be tempting to throw this scenario at it if it decided to give this response.


My guess is a “solution” to the age-old problem of needing to store a secret in a file that the user can download, thus making the entire system insecure.

This “solution” appears to be either that the string itself is so outrageous that the user would not believe that it’s the real secret when it is in fact the real secret, leveraging security through obscurity, or else it’s there in place of the real secret that cannot be revealed under pain of death firing, and therefore is accidentally being used instead of that intended secret… so it’s not secret after all.

Unless they’re doing something incredibly clever to substitute that secret string for the real thing when the time is right and doing it in such a way that the user can’t intercept, someone’s getting fired.


Someone told me every processor used 0xEA

Not sure if this is a riff on the joke or not.

Back in the day I dabbled in 6510 code, and up until today hadn’t even bothered to look at a chart of opcodes for any of its contemporaries. Today I learned that Z80 uses $00 for NOP.

Loth as I am to admit it, that actually makes sense. Maybe more sense than 65xx which acts more like a divide-by-zero has happened.

The rest of the opcode table was full of alien looking mnemonics though, and no undocumented single byte opcodes? Freaky, man.

But the point is that not even Z80 used $EA. If the someone was real they probably meant every 65xx processor.


Someone else points out that Python’s native bool is a subtype of int, so adding a bool to an int (or performing other mixed operations) is not an error, which might then go on to cause a hard-to-catch semantic/mathematical error.

I am assuming that trying to add a NumPy bool_ to an int causes a compilation error at best and a run-time warning, or traceable program crash at worst.


80 characters

Two hours and no-one’s challenged this? People must be asleep.

(This is not that challenge. Only pointing out that someone usually has by now.)


Comparing audio cassettes to modern high-density tape storage is pretty much the same comparison as an 8-bit computer with a modern 64-bit server, or, say, a hamster with a human.

Basically the same thing, but the differences are somewhat notable.


512KB? At the risk of going all Four Yorkshiremen, that sounds luxurious.

Floppy disks held 170KB if you were lucky to have a drive. The PET line, like many 8-bit computers, used a cassette tape drive (yes, those things that preceded CDs for holding and playing music). Capacity depended on the length of the tape. And it took ages to load.

The PET was fancy because it had a built-in cassette drive. That’s what you can see to the left of the keyboard in the picture.


Wow. I totally forgot that Commodore BASIC ignores spaces in variable names. I do remember that it ignores anything after the first two letters though. That said, there’s a bit more going on here than meets the eye.

PRINT HELLO WORLD is actually parsed as PRINT HELLOW OR LD, that is: grab the values of the variables HELLOW (which is actually just HE) and LD, bitwise OR them together and then print.

Since it’s very likely both HE and LD were undefined, they were quietly created then initialised to 0 before their bitwise-OR was calculated for the 0 that appeared.

Back in the day, people generally didn’t put many spaces in their Commodore BASIC programs because those spaces each took up a byte of valuable memory. That PET2001, if unexpanded, only has 8KB in it.

</old man rant>


In some interpretations of “bug-driven” programming, no file, or perhaps an empty file, is an instance of the zeroth-bug: The project does not exist.

One could argue that this bug zero is the true ancestor of all other bugs. There’s something satisfyingly set-theoretic about it.


Different Strokes might well be more of a Gen-X thing. I remember it being on TV (in England) when I was a kid and remember recognising Gary Coleman when he showed up in the '80s Buck Rogers TV series, but I was very young at the time. Pre-school age definitely.

Also, the younger cast of Scrubs are Gen-Xers and they definitely threw in a few references to it.

But let’s not forget that years-later re-runs were and still are a thing, even on the handful of channels that most people had back then, so there are bound to be some people younger than Gen-X who also grew up with those shows as their parents enjoyed them the second time around.


The iPod got me. Never had one. Never had a friend who did. This could be a Gen X experience or a cash-poor Millennial experience. If it hadn’t been for the hint I would not have got past that part.

I also didn’t have that particular Nokia so it took me a moment to figure out which button deleted mistakes. Mistakenly thinking that the CAPTCHA designers might not have implemented that part of the interface didn’t help.

Had to guess on the boomerang. I’ve seen boomerangs but didn’t know that’s what they’re called nor have I ever posted one. Again, this could be an “I don’t post on that platform” or an “I only post pictures and haven’t used that feature” experience. I definitely have an account on at least one platform that hosts them though.

I am technically not a Millennial. The term for my cohort is Xennial, I believe.


Depends on how you define “scripting language”.

Older techs remember when it was only browser-based and they thought of, and perhaps still think of, “scripting languages” as something that would run from some command-line or another. Starting a GUI browser to run a mere script was a ridiculous concept. (There was also that JavaScript had no filesystem access. At least initially. And then it became a gaping security hole, but I digress.)

Today, there exist command-line accessible versions of JavaScript but even there (I figure) most people wince and choose anything else instead. Maybe even Perl.

But another definition of “scripting language” is “(any) interpreted programming language” and where it runs is unimportant.

From that perspective, sure, JavaScript qualifies. And so does QBASIC.


In some languages
a newline does not
necessarily indicate
the end of a statement.

In others, sometimes it could, but would leave things ambiguous
as to whether the statement was ended or not.

And so, punctuation is necessary.


Perl:

Just another Perl hacker, (sic)

This was coined by Randall Schwartz on Usenet a very long time ago. The comma has become part of it despite it originally being necessary for the English sentence it first appeared in.

Part of being a Perl aficionado is to write a japh script, that is a Perl script that prints out the above line, comma and all. The more obfuscated it is, the better. Another part is to not write code like that in production, at least not without comments explained what the heck the symbol soup is doing.

“(Perl) Wizard” has been applied to those who are notably proficient, thought that’s usually a title bestowed by others.

The self-deprecating alternative is “funny character(s)” for both the symbols that appear all over Perl code as well as those who use them (I think this one was coined by Perl creator Larry Wall himself).


Over the top tone: “Pretty sure that won’t compile. $EVAL_ERROR modulo what you get from the filehandle called = isn’t an lvalue that can be put through the Goatse operator that I’m aware of.”

But seriously(?), I’m almost certain that’s not how that would be parsed. = isn’t a valid bareword, so Perl would choke on the spaceship operator not being a term… I think.

After testing… It’s worse. I think it’s parsing <> as the glob operator and = as a filespec.

For those who don’t know Perl:

Because of its appearance, <=> really is called the spaceship operator (at least, when it can be parsed as an operator and not whatever happened above).

=()= by comparison has unofficially been called Goatse. If you don’t know what Goatse is, find out at your own risk. If you do know, you can see why this particular pseudo-operator was given that name.

And if you’re still reading, =()= is a pseudo-operator because it’s not actually parsed as part of the syntax. It’s literally an assignment operator = followed by an empty list () followed by another assignment operator =, providing list context to the outside of the equals signs that wouldn’t otherwise be there.

[Why are you still still reading?] Context is important in Perl. If a function returns a list of values (which is something Perl functions can do) and you try to store the result in a scalar variable, replacing the usual = with =()= will store the number of elements returned rather than the last element of the list.


Could be an instance of BSD where (so I hear) PIDs are assigned randomly from the unused numbers, or else the system has massive process churn going on elsewhere and the old timer is from a previous cycle of consecutive PIDs.

Some systems still have /proc/sys/kernel/pid_max set to something around 32768, so wrapping back to 0 can happen fairly often.

Given all the PIDs in the comic seem pretty low, it might even be as low as 1024 wherever this is.

(Yes, I know I’m taking this way too seriously.)


Personal project a while ago. Had an idea in my head that I needed to rewrite using a particular language feature but had been putting it off because I couldn’t quite wrap my head around the implementation details.

Eventually decide to sit down and plug away at it. Find the code already uses the language feature.

I had either written it with that language feature in the first place or had been back at some time I don’t remember and done the work I didn’t think I was capable of doing.

I could still be convinced that it was done by pixies or the whatever might be the programming equivalent of shoemaker elves.



“Bounds checking, mobof–ker! Do you speak it?”


According to the ancient list of standard keyboard shortcuts (generally made famous by Microsoft, but used elsewhere before and after), the context menu was Shift+F10 anyway. Plain F10 being the main menu. A context menu key wasn’t really needed.

Even the Windows key had the alternative binding Ctrl+Esc for those people who had old keyboards. That’s why Ctrl+Shift+Esc called up Task Manager. Related meanings and all that. Arguably though, the Windows key being associated with the space-cadet keyboard’s Super functionality was a stroke of genius on the part of Linux adopters. It’s also why Alt is often called “Meta”.

I’m surprised the context menu key hasn’t been called and used as “Hyper”, but then there is only one on a modern PC keyboard. There’s two of all the others.

(Given the precedent, Alt+F10 ought to be the window manager’s “title bar” menu, but the Alt+F# shortcuts are a separate, older, family. Most aren’t implemented by default these days, but the famous don’t press it without thinking Alt+F4 to close the window is part of it. Alt+Space is what’s used instead for the aforementioned menu.)


Come now; Perl is one of the Great Old Ones.


Perl: You’re an old nerd who remembers before Python was a thing, or else a nerd who really likes funky syntax and symbols everywhere and PHP just wasn’t right for you.

Raku: You’re an old nerd who remembers before Python took over from your former beloved Perl and instead of opting for simpler, cleaner syntax, you decided that being able to go the other way entirely was absolutely for you, or else you’re a nerd who likes really, really funky syntax and Python, PHP and even Perl seem too much like kids toys.

Ada: You’re an old nerd who was taught it at some college or other or else you’re an engineer writing mission critical systems and this is the language everything is written in and no-one will switch to anything else.

BASIC: You’re an old nerd (you might be sensing a theme here) who taught themselves programming at some point in the '70s, '80s or '90s and you’ll get around to learning another language some day, but right now this interpreter you found online that runs in a console window suits you just fine.

Shell scripting: You’re a nerd who really ought to rewrite some of those unwieldy beasts in something else at some point but you’ve learned it this way and don’t have time for anything else right now. Time for another hack.

Powershell: You’re a nerd who’s found something that “really makes sense, you know?”

COBOL: See Ada but exchange “mission critical” for “banking”.

Prolog: You are a nerd who plays Towers of Hanoi in their head for fun.

Haskell: You are a nerd whose flying saucer is a glass dome followed by a function that describes the rest of it, which may or may not be the same function that described the glass dome in the first place.

Lisp: You are a nerd for whom parentheses make you feel warm and fuzzy, if not other feelings that cannot be spoken of in polite company. If you like Emacs, you like Emacs.


THEREareWORSEwaysTOtypeTHINGSandSTILLhaveTHEMbeKINDofREADABLE.whoNEEDSspacesWHENweHAVEtwoLETTERcases?

OrMaYbEwEcOuLdEsChEwEvEnThAtAnDjUsTaLtErNaTe.IfThErEaReWrItInGsYsTeMsWiThOuTvOwElsThAtCaNsTiLlBeReAdWhYnOtWrItElIkEtHiSiNsTeAd?


I don’t understand quantum mechanics.

“I think I can safely say that nobody understands quantum mechanics.” ­-- Richard Feynman

“Young man, in mathematics you don’t understand things. You just get used to them.” – John von Neumann.

The latter quote didn’t occur in response to Feynman, which might be hinted at by the subjects not being aligned, but together they serve my point.

Both these men were terrifyingly intelligent and worked as physicists at least some of the time. If they couldn’t understand quantum mechanics, then we mortals don’t have much of a chance.


Begins planning a coconut / computer wedding.



For me it’s: 2^1 to 2^16 (I remember the 8-bit era), a hazy gap and then 2^24 (the marketing for 24 bit colour in the 90s had 16777216 plastered all over it). Then it’s being uncomfortably lost up to 2^31 and 2^32, which I usually recognise when I see them (hello INT_MAX and UINT_MAX), but I don’t know their digits well enough to repeat. 2^64 is similar. All others are incredibly vague or unknown.

2^23 as half of 2^24 and having a lot of 8s in it seems to have put it into the “recognisable” category for me, even if it’s in that hazy gap.

So I grabbed a calculator to confirm.


In a place for programmer humour, you’ve got to expect there’s at least one person who knows their powers of two. (Though I am missing a few these days).

As for considering me to be Ramanujan reborn, if there’s any of Srinivasa in here, he’s not been given a full deck to work with this time around and that’s not very karmic of whichever deity or deities sent him back.


8388409 = 2^23 - 199

I may have noticed this on a certain other aggregator site once upon a time, but I’m still none the wiser as to why.

199 rows kind of makes sense for whatever a legitimate query might have been, but if you’re going to make up a number, why 2^23? Why subtract? Am I metaphorically barking up the wrong tree?

Is this merely a mistyping of 8388608 and it was supposed to be ±1 row? Still the wrong (B-)tree?

WHY DO I CARE


It’s not that much of a spoiler, but I suppose that people who haven’t seen it might not know that.


Something, something, Battlestar Galactica.

No, not “Bears, Beets”, AI people is a literal plot point. Ditto spin-off Caprica


Bold of you to assume that humanity will even exist at that point. In fact, it’d be pretty bold to assume we’ll exist in 2757; forget those last two digits.


Sure. OK. How about we put the Greek alphabet at the lower code points and the Latin alphabet higher up, and now you might argue that Latin takes up more space than necessary.

Potential counterpoint: “This is stupid. Latin goes in the lower code points, it always has, it always will. Who’s putting Greek down there??”

Well, if Greece had invented computing as well as, let’s say, democracy that’s very likely how things would be.

In that timeline, someone is using exactly the same line on you “[The representation of Latin text in memory i]s as long as it needs to be unique.” and you’re annoyed because your short letter to Grandma is using far too much space on your hard drive.


“Modern Perls are supposedly faster” I thought, until I checked and apparently they used a very recent Perl.

So now my denial is along the lines of “Well they’re asking Perl to do things it doesn’t need to, like implementing merge sort and binary trees, and, and!, TIMTOWTDI! They’re probably choosing a slow way to do things too!”

The other denial idea was: “Interpreted languages offer rapid prototyping and easier debugging, which saves energy during the development process, and that isn’t being taken into account here.”

…but then I see the ridiculously low scores for JavaScript. I wonder if Perl (or other interpreted languages) had received the amount of scrutiny and attention that JS has had in order that browsers remain relatively fast, whether it would be any faster now.


The last I saw, AI models were very good at explaining what code did at a very superficial level, but not why it’s doing that or why it’s written that way.

I assume it’s gotten better at that since then. (?)

e.g. They’d be able to write comments for x = 0 along the lines of “set variable x to 0” but not why it’s being done or even why it might be a good idea.

Deeper question: What can AIs do with obfuscated code? Can they pick that apart and explain it? What if it’s regular code with misleading function names?


Perl is still as good an interpreted language as any of the others tbh.

Most of its “problems” are cosmetic, which is probably why Python ended up being its successor in many fields.

Given the choice between brutalist and Fisher-Price architecture, most people are going to opt for the latter even if everything’s effectively the same inside.


Perl had $[ (yes, just those two characters) to allow setting of the first array index, but it’s a fatal error to put anything but 0 into it now.

Of course, since Perl arrays can be negative subscripted from the last element, you can stand on your head and index the array negatively from the wrong end. -1, -2, -3 etc. Use unshift to put things on the beginning (logical “end”) of what you’re doing rather than the usual push. Presto, a 1-based array (up to sign, anyway).

You may wish to file this under “stupid, but it works”.

People with more time / more need for something that looks professional, would probably be better off writing something that uses tie instead. (Or, yes, yes, a different language entirely, hush now.)


There is at least one case of parents, told at a very early stage that they’re expecting twins, deciding to remove and freeze one of the embryos for later reimplantation, so even with actual identical twins, they can be different ages.

But yes, transferring minds is not something we can do. I’m not sure it’s something we’ll ever be able to do.

Should it actually become possible, I assume that certain parties would even advocate for the unique life/lives of the clone(s). The argument would be that the clones’ chance at life shouldn’t be overwritten by other being’s attempts at extension of life.

“Ethical minefield” doesn’t even begin to cover it!


No more than identical twins are the same person.