What are the Usage of Tuple?

Category: C SharpWhat are the Usage of Tuple?
Editor">Editor Staff asked 2 years ago

What are the Usage of Tuple?

1 Answers
Editor">Editor Staff answered 2 years ago

Tuples can be used in the following scenarios:

When you want to return multiple values from a method without using ref or out parameters.
When you want to pass multiple values to a method through a single parameter.
When you want to hold a database record or some values temporarily without creating a separate class.