home.social

#namedtuple — Public Fediverse posts

Live and recent posts from across the Fediverse tagged #namedtuple, aggregated by home.social.

  1. [Перевод] Скрытая цена словарей Python и три более безопасные альтернативы

    Команда Python for Devs подготовила перевод статьи о том, почему словари Python могут незаметно подводить в продакшне и какие альтернативы помогают ловить ошибки раньше. В тексте разбираются dict , NamedTuple , dataclass и Pydantic — от быстрого прототипирования до строгой валидации данных.

    habr.com/ru/articles/979024/

    #python #dataclass #namedtuple #pydantic #валидация #словари

  2. Named Tuples in Python:
    A named tuple lets you create lightweight, immutable objects with named fields for better readability and access than regular tuples.
    #Python #PythonTips #NamedTuple #CodingTips #LearnPython #PythonDeveloper #CodeSmarter #100DaysOfCode #PythonHack #TechTip

  3. Testing the Performance of Python Named Tuples: are named tuples slower than ordinary ones? Let's find out. (Spoiler alert: yes, a bit.)

    codedrome.substack.com/p/testi

    #python #programming #tuple #namedtuple