• 0 Posts
  • 427 Comments
Joined 1 year ago
cake
Cake day: September 13th, 2023

help-circle
  • AVincentInSpace@pawb.socialtoMemes@sopuli.xyzYou don't need to answer this
    link
    fedilink
    English
    arrow-up
    1
    arrow-down
    1
    ·
    edit-2
    3 months ago

    Ah yes, let me just boycott my health insurance provider. Since it’s provided through my work, it’s real easy and convenient (not to mention cheap!) to switch to a different provider. And as for socialized medicine I’m sure Congress will get right on that, just as soon as the Democrats have a majority in the Senate. What’s that? They already had that and they sat with their thumbs in their asses not passing any laws because of something something bipartisanship? No matter, I’m sure it’s fine. If we put them in charge again I’m sure things will be different! We just need to vote!










  • Because to a certain extent Python is duck typed. Python has no concept of interfaces, unless you count the abc module combined with manual isinstance() checks, which I’ve never seen anyone do in production. In order to be passed to some function that expects a “file-like object”, it just has to have methods named read(), seek(), and possibly isatty(). The Python philosophy, at least as I see it, is “as long as it has methods named walk() and quack(), it’s close enough to a duck for me to treat it as one”.

    Duck typing is distinct from weak type systems, though.