• 2 Posts
  • 280 Comments
Joined 1 year ago
cake
Cake day: August 4th, 2023

help-circle




  • I’ve got my caps lock key remapped to escape.

    I use my left pinky for ctrl, shift, a, and my remapped caps lock/escape key.

    I use my right pinky for shift, enter, and I’m pretty sure that’s all.

    I use my ring fingers for backspace, tilde, tab, q, backslash, quote, and that probably isn’t a comprehensive list.

    I use my middle finger for semicolon/colon! I never realized that before. Wild.













  • Honestly, this isn’t much of a hypothetical for me. At work, my choices are Windows, Mac, or Ubuntu. I’m quite happy with Ubuntu, though I’ve switched away from the default desktop environment to i3.

    I use Arch (BTW) on my personal systems. And Ubuntu isn’t as bad as I worried it would be.

    My main gripe is snaps. Firefox is practically unusable as a snap. And my employer forbids installing any software (save for a select list of exceptions) not via the officially-supported Ubuntu way of doing things. Chrome is available without snap, so I use it on my work machine. Which annoys me, but if I’m less efficient in my job as a result, it’s their own fault.



  • Yeah, #2 is both more space efficient and more time efficient.

    How I’d generally do something like that:

    1. Create an empty linked list.
    2. Generate a random integer between 0 and 51 inclusive.
    3. Iterate over the linked list and increment the random integer by one for each integer in the linked list less than or equal to your newly-generated random integer. You can break out of that loop as soon as you hit the first integer in the linked list greater than the newly-generated integer.
    4. Binary insert that integer into the sorted linked list.
    5. For the denomination, output the newly-generated integer modulus 13 plus one. Translate 1 to ace, 11 to jack, etc.
    6. For the suit, output floor of the newly-generated integer divided by 4 plus one. (Translate zero to “hearts”, one to “diamonds”, etc.)
    7. Loop back to step 2 51 more times.

    Step 3 can definitely be optimized much more with a B-tree and a little thought. If you want jokers included, it’s pretty straightforward. (Just change step 2 to generate a random integer between 0 and 53 and tweak steps 5, 6, and 7.)


  • I was really excited for CJDNS (not to be confused with “Domain Name System”) at one time. It’s a mesh networking protocol. And they’d established an “Internet 2” (as in, a sequel to “The Internet”) based on the CJDNS protocol called “Hyperborea.”

    I haven’t heard anything about CJDNS in a good while now. I wouldn’t be surprised if there were other efforts looking to do something roughly the same, but I’m not up to date on anything more recent.