• 1 Post
  • 147 Comments
Joined 5 years ago
cake
Cake day: May 31st, 2020

help-circle
  • Ephera@lemmy.mltoMemes@lemmy.mlGetting harder as I get older
    link
    fedilink
    English
    arrow-up
    2
    ·
    edit-2
    57 minutes ago

    Today, a colleague couldn’t do docker login for an internal registry. Constantly got an error which just said “unauthorized”.
    The password couldn’t be the problem, because you actually generate a token on the registry webpage, so we tried all the different ways to spell his username (uppercase, lowercase, e-mail address) and tried different URLs for specifying the registry, tried toggling the VPN, a reboot etc., even though we knew what should work, because the login worked for me.

    Eventually, we gave up and figured there must be some permission problem in the registry. Ten minutes later, he tells me that it works, without doing anything different. Now I’m wondering, if the IT saw our desperate login attempts and quickly fixed the problem. 🫠




  • It won’t rise much beyond that, since you only get one update per package. Whether it’s upgrading Firefox from version 120 to 121 or to version 130, it doesn’t change much in terms of download size, nor the number of updates.

    At least, I assume, Arch doesn’t do differential updates. On some of the slower-moving distributions, they only make you download the actual changes to the files within the packages. In that case, jumping to 121 vs. 130 would make more of a difference.

    If you do want lots of package updates, you need lots of packages. The texlive-full package is always a fun one in that regard…






  • Ephera@lemmy.mltoMemes@sopuli.xyzBinary search
    link
    fedilink
    English
    arrow-up
    4
    ·
    24 hours ago

    You know, after posting that comment, I really doubted myself, if it really is binary search, because Wikipedia also tells me it needs to be a sorted array.

    But yeah, I think that’s only relevant, if your method of checking whether it’s in one half or the other uses > and <. As far as I can tell, so long as you can individually identify the fuses, a.k.a. they’re countable, then you can apply binary search.


  • Ephera@lemmy.mltoMemes@sopuli.xyzBinary search
    link
    fedilink
    English
    arrow-up
    12
    arrow-down
    1
    ·
    1 day ago

    Oh, well, you switch off half the fuses, then you go check the wire.
    Let’s say the wire still has power on it, so now you know that none of the fuses in that half affected it (which you can turn back on now).

    Then you do the same thing again with the other half of the fuses, i.e. you switch off half of the fuses in that half and go check the wire.
    Now, let’s say the wire is dead, so now you know that the fuse you want is in this quarter.

    So, then you flick off half of the fuses in that quarter and check the wire again, and so on.

    With every step, you eliminate half of the remaining fuses, so for 60 fuses, you need at most 6 steps (which is the logarithm for base 2 of 60).


  • Ephera@lemmy.mltoMemes@sopuli.xyzBinary search
    link
    fedilink
    English
    arrow-up
    53
    arrow-down
    1
    ·
    edit-2
    24 hours ago

    My dad once told me that he had to find the circuit breaker that corresponded to a particular wire and because we have around 60 circuit breakers in our house, he had to flick one off, run down and check the wire, run back up, flick the next circuit breaker off, and do that quite a lot of times.

    In that moment, I got to explain binary search to him and he was genuinely interested. 🙃









  • I agree with the notion, but at the same time, I think no one wants to deal with the mess of having two different kinds of Ethernet plugs. I mean, if you think about it, needing dongles for connecting Ethernet to USB-C is exactly what would happen, if you had two different Ethernet plugs. So, at this rate, might as well start having USB-C ports on routers, so you can run a USB-C cable all the way…