Was going through a Python tutorial, but it seems kinda dated. Wanted to know if people regularly use docstrings in the workforce. Or are they somewhat irrelevant because you can convey most of that info via comments and context? Do jobs make you use them?

  • 3rr4tt1c@programming.devOP
    link
    fedilink
    English
    arrow-up
    2
    ·
    edit-2
    8 days ago

    Sounds like they’re still very relevant and very important. Python isn’t a language I’ve used a lot but I’m still surprised I’ve never heard about docstrings till this tutorial. Thanks for the info.

    • heavydust@sh.itjust.works
      link
      fedilink
      arrow-up
      1
      ·
      4 days ago

      I wouldn’t say it’s “more important” in Python but usually: 1. Documentation is very important in every language, and 2. Python uses docstrings to achieve this.