4,830 results
Open links in new tab
  1. Python Functions - W3Schools

    Python Functions A function is a block of code which only runs when it is called. A function can return data as a result. A function …

  2. Python Functions - GeeksforGeeks

    Sep 19, 2026 · Defining a Function A function can be defined using def keyword. Below is the syntax to define a function: Syntax of …

  3. How to Define a Function in Python (def, Call, Return)

    Oct 20, 2026 · Learn how to define a function in Python with def: parameters, return values, naming rules, docstrings, type hints, and …

  4. Python Functions (With Examples) - Programiz

    In this tutorial, we will learn about the Python function and function expressions with the help of examples.

  5. What does -> mean in Python function definitions?

    Jan 17, 2013 · It's a function annotation. In more detail, Python 2.x has docstrings, which allow you to attach a metadata string to …

  6. Python 3.15.2 documentation

    1 day ago · What's new in Python 3.15? Or all "What's new" documents since Python 2.0 Tutorial Start here: a tour of Python's …

  7. Python - Functions - Online Tutorials Library

    A Python function is a block of organized, reusable code that is used to perform a single, related action. Functions provide better …

  8. The Python Language Reference — Python 3.15.2 documentation

    1 day ago · The Python Language Reference ¶ This reference manual describes the syntax and core semantics of the language. It is …

  9. Python Cheat Sheet

    Compact Python cheat sheet covering setup, syntax, data types, variables, strings, control flow, functions, classes, errors, and I/O.

  10. Defining Your Own Python Function

    Oct 24, 2026 · Learn how to define your own Python function, pass data into it, and return results to write clean, reusable code in …