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

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

Was on kbin.social (dying/dead) and kbin.run (mysteriously vanished). Now here on fedia.io.

Really hoping he hasn’t brought the jinx with him.

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

  • 0 Posts
  • 53 Comments
Joined 3 months ago
cake
Cake day: August 13th, 2024

help-circle



  • Find yourself a language that allows negative indices to count back from the end of an array.

    In those languages, index 0 is usually the first element, but if you’re particularly perverse and negate your indexing, you can start at 1, or rather -1, at the other end and work backwards.

    0-indexing originally comes from needing to add to the array’s base memory address to locate elements. If you have an array at memory address 1234, you might expect to find the first element at that address, which would be 1234+0, and the next at 1234+1, etc.

    1-indexing started as either a deliberate abstraction from that idea, and/or else there’s something else stored at 1234 that the array data type needs and the real elements start at 1234+1.

    All that said, there’s at least one language that insists the indices of an array be of a subtype of some Integer type that must have a limited range. Then you can start and end wherever you like, and the whole 1 vs 0 business is meaningless (except to whoever writes the compilers for that language anyway).
















  • The reason people aren’t bothering is that we’ve gone all USA healthcare with regard to the vaccines. If you want one, find a pharmacy that will provide one and be prepared to cough up at least £40. And be sure to shop around and/or be prepared to travel because some places charge £100.

    A whole lot of people don’t have even the low end of that kind of money, even if “the right thing to do” would be to make sacrifices - like, say, go cold or hungry for a couple of weeks, how hard could that be? - in order to make sure they get it. And then do the same again every six months from now until something else kills them.

    And even if someone has £100 to spare, that’s a lot of money that could be spent on something other than feeling like crap for three days.

    There are exemptions (i.e. free vaccines) for those over 64, the infirm, and health workers, but the rest of us can suck it, apparently.

    Source: https://www.bbc.co.uk/news/health-55045639