About 51 results
Open links in new tab
  1. What does -> mean in Python function definitions? - Stack Overflow

    Jan 17, 2013 · def foo() -> lambda hi: True: "function body" # not a type expressions Beside the first the others have no typing meaning; but it still is valid syntax to hide a lambda definition in the return …

  2. What is a DEF function for Python - Stack Overflow

    Sep 10, 2013 · I am new to coding Python and I just can't seem to understand what a Def function is! I have looked and read many tutorials on it and I still don't quite understand. Can somebody explain to …

  3. python - Differences between `class` and `def` - Stack Overflow

    What is the main difference between class and def in python? Can a class in python interact with django UI (buttons)?

  4. python - What does def main () -> None do? - Stack Overflow

    As is, it does absolutely nothing. It is a type annotation for the main function that simply states that this function returns None. Type annotations were introduced in Python 3.5 and are specified in PEP …

  5. Groovy: what's the purpose of "def" in "def x = 0"?

    Oct 9, 2008 · The def keyword can be removed, and this snippet would produce the same results. So what's the effect of the keyword def ?

  6. How do you use input function along with def function?

    Jun 9, 2015 · How do you use input function along with def function? Asked 10 years, 11 months ago Modified 1 year, 3 months ago Viewed 107k times

  7. Using len () and def __len__ (self): to build a class

    Feb 27, 2013 · Just curious, Is there any difference (advantages and disadvantages) between using len () or def __len__ () when I build a class? And which is the best Python style? class foo (object): def

  8. Why am I getting a NoClassDefFoundError in Java?

    I am getting a NoClassDefFoundError when I run my Java application. What is typically the cause of this?

  9. What is the purpose of __str__ and __repr__? - Stack Overflow

    Called by the repr() built-in function and by string conversions (reverse quotes) to compute the "official" string representation of an object. If at all possible, this should look like a valid Python expression …

  10. python calling a def () inside of def () - Stack Overflow

    Aug 1, 2018 · python calling a def () inside of def () Asked 7 years, 9 months ago Modified 3 years, 7 months ago Viewed 32k times