About 3,330,000 results
Open links in new tab
  1. Fit data with any function and check when it reaches certain value

    Mar 12, 2019 · After removing the single data point with the smallest X value (the left-most point on a scatterplot) I was able to easily fit the remaining data to the equation "y = a*ln(x+b)", …

  2. Python's "in" and "not in" Operators: Check for Membership

    Jan 26, 2025 · In this tutorial, you'll learn how to check if a given value is present or absent in a collection of values using Python's in and not in operators, respectively. This type of check is …

  3. Python Functions - W3Schools

    In Python a function is defined using the def keyword: To call a function, use the function name followed by parenthesis: Information can be passed into functions as arguments. Arguments …

  4. python - Evaluating a function at a specific point - Stack Overflow

    Jun 18, 2019 · I am trying to write a Python function called term_output that can evaluate what a single term equals at a value of x . For example, when x=2 , the term 3x^2 = 3*2^2=12 . I've …

  5. python - How can I take a users input as a hit or stay to …

    Mar 5, 2021 · You should not be assigning player1/player2 in this function. You should have a single function that translates "dice" to "score". Then, you can apply it to player1 in a loop, and …

  6. Python return statement - GeeksforGeeks

    Dec 10, 2024 · Python allows you to return multiple values from a function by returning them as a tuple: Example: In this example, the fun () function returns two values: name and age. The …

  7. Python Functions - Python Guides

    Find the Maximum Value in Python Using the max() Function; Use the Python pop() Function; Use the repeat() Function in Python; Use the ceil() Function in Python; ... Learn about Functions in …

  8. Python Function: The Basics Of Code Reuse

    Oct 31, 2023 · Learn how to create and use a Python function with Python's def keyword, why functions are useful, and learn about variable scope.

  9. Python Function Guide with Examples - freeCodeCamp.org

    Jan 28, 2020 · Functions in Python are created using the def keyword, followed by a function name and function parameters inside parentheses. A function always returns a value,The …

  10. Python Functions - GeeksforGeeks

    Mar 10, 2025 · We can define a function in Python, using the def keyword. We can add any type of functionalities and properties to it as we require. By the following example, we can …

Refresh