22,800 results
Open links in new tab
  1. Python len () Function - W3Schools

    The len() function returns the number of items in an object.

  2. Python len() Function - GeeksforGeeks

    Jul 1, 2026 · Explanation: len (text) calculates the number of characters in the string, "Programming" contains 11 characters and …

  3. Using the len () Function in Python

    Nov 16, 2024 · In this tutorial, you'll learn how and when to use the len() Python function. You'll also learn how to customize your …

  4. Built-in Functions — Python 3.11.18 documentation

    The len gth of the tuple must exactly match the number of free variables referenced by the code object. Raises an auditing event …

  5. len () Function in Python (With Examples)

    Oct 10, 2026 · The Python len() function with real output: length of strings, lists, dictionaries, sets and ranges, characters vs bytes, …

  6. len () | Python’s Built-in Functions – Real Python

    Reference Python’s Built-in Functions / len () The built-in len () function returns the number of items in an object, such as sequences …

  7. Python len ()方法 - 菜鸟教程

    Python len ()方法 Python 内置函数 描述 Python len () 方法返回对象(字符、列表、元组等)长度或项目个数。 语法 len ()方法语法: …

  8. python - Difference between len () and .__len__ ()? - Stack Overflow

    Well, len (s) is a built-in Python method which returns the length of an object. Now __len__ () is a special method that is internally …

  9. Python len ()

    In this tutorial, you will learn how to use the Python len() function to get the number of items of an object.

  10. Python __len__ () magic method - GeeksforGeeks

    Jul 23, 2025 · Python __len__ is one of the various magic methods in Python programming language, it is basically used to …