About 13,400,000 results
Open links in new tab
  1. How does tuple comparison work in Python? - Stack Overflow

    Tuples are compared position by position: the first item of the first tuple is compared to the first item of the second tuple; if they are not equal (i.e. the first is greater or smaller than the …

  2. python - What is a tuple useful for? - Stack Overflow

    Sep 9, 2014 · A tuple is a good way to pack multiple values into that cookie without having to define a separate class to contain them. I try to be judicious about this particular use, though.

  3. Python typing: tuple [str] vs tuple [str, ...] - Stack Overflow

    Apr 25, 2022 · Python typing: tuple [str] vs tuple [str, ...] Asked 3 years, 7 months ago Modified 3 years, 7 months ago Viewed 8k times

  4. What's the difference between lists and tuples? - Stack Overflow

    Mar 9, 2009 · What are the differences between lists and tuples, and what are their respective advantages and disadvantages?

  5. c# - How to name tuple properties? - Stack Overflow

    How and "could be" organized return from the method which returns tuple type with the name of parameters, as an example private static Tuple<string, string> methodTuple() { return new …

  6. Returning multiple values from a C++ function - Stack Overflow

    Aug 19, 2015 · 3 Boost tuple would be my preferred choice for a generalized system of returning more than one value from a function. Possible example:

  7. types - What are "named tuples" in Python? - Stack Overflow

    Jun 4, 2010 · Named tuples are basically easy-to-create, lightweight object types. Named tuple instances can be referenced using object-like variable dereferencing or the standard tuple …

  8. What's the difference between System.ValueTuple and …

    Dec 14, 2017 · 40 The difference between Tuple and ValueTuple is that Tuple is a reference type and ValueTuple is a value type. The latter is desirable because changes to the language in C# …

  9. Python type hints for function returning multiple return values

    Sep 25, 2019 · 12 Multiple return values in python are returned as a tuple, and the type hint for a tuple is not the tuple class, but typing.Tuple.

  10. c# - Return multiple values to a method caller - Stack Overflow

    The tuple probably is the best option for readability. Personally, I'm not keen on having anonymous types or property names like Item1 - although I guess destructuring does mitigate …