Top "Tuples" questions

In programming, tuples are simple *product types*, representing ordered collections of types.

Converting a C char array to a String

I have a Swift program that does interop with a C library. This C library returns a structure with a …

arrays swift interop tuples
C# 7 tuples and lambdas

With new c# 7 tuple syntax, is it possible to specify a lambda with a tuple as parameter and use unpacked …

c# lambda tuples c#-7.0
Implementing comparison operators via 'tuple' and 'tie', a good idea?

(Note: tuple and tie can be taken from Boost or C++11.) When writing small structs with only two elements, I …

c++ c++11 operators tuples strict-weak-ordering
How to use priority queues in Scala?

I am trying to implement A* search in Scala (version 2.10), but I've ran into a brick wall - I can't …

scala tuples priority-queue scala-collections
How to Get key value pair tuple array in swift?

I have pairs tuple array pickerDataVisitLocation.just I want to know how to return key value pair location from my …

ios arrays swift tuples key-pair
How to flatten a nested tuple?

I have a nested tuple structure like (String,(String,Double)) and I want to transform it to (String,String,Double). …

scala tuples flatten
How can I explode a tuple so that it can be passed as a parameter list?

Let's say I have a method definition like this: def myMethod(a, b, c, d, e) Then, I have a …

python parameters tuples iterable-unpacking
Unpacking tuples in a python list comprehension (cannot use the *-operator)

I am trying to create a list based on another list, with the same values repeated 3 times consecutively. At the …

python tuples list-comprehension iterable-unpacking
Surprising Tuple (in)equality

Until today, my understanding of .NET Tuple classes had been that they delegate their implementation of Equals() to their contents, …

c# equality tuples
C++11 use-case for piecewise_construct of pair and tuple?

In N3059 I found the description of piecewise construction of pairs (and tuples) (and it is in the new Standard). …

c++11 tuples use-case forwarding piecewise