Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6574571
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 25, 20262026-05-25T15:16:40+00:00 2026-05-25T15:16:40+00:00

We have been discussing Tuple and its various possible uses. In almost all cases

  • 0

We have been discussing Tuple and its various possible uses. In almost all cases it sounds like root of evil, it makes design worse, and generally calls for a specialized class instead of Tuple everywhere it could be used.

It is supposedly close to DB but its hard to find a use for Tuple in db persistant logic code too.

Has anyone any real world good sample of Tuple use , preferably closer to some real world domain model problem or any use actualy.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-25T15:16:40+00:00Added an answer on May 25, 2026 at 3:16 pm

    Tuple is said to have been introduced to .NET 4 because some programming languages (let’s say, for example, IronPython or F#) support tuples as a core feature of the language, and the .NET BCL team wanted to provide a uniform tuple type for such languages (for language interoperability reasons, I guess):

    The BCL team decided to work with the F# team to standardize on one tuple type for the framework so that every language could benefit from them. (in Eric Lippert’s answer to the SO question, What problem was the tuple designed to solve?
    )

    Tuple does not make much sense in the C# language IMHO, because C# doesn’t support tuples and some associated language constructs very well; e.g. tuple “explosion”: spreading a tuple over a function’s parameters, or taking a function’s return values (in the form of a Tuple) and spreading it over several local variables:

    Tuple<int,int>  GetFoo() { … }
    //     v   v
    int   (a,  b) = GetFoo();  // C# doesn't support this tuple-related syntax.
    

    That being said, if you’re writing only C# code, you can usually find “better”, more structured solutions than using Tuple. For example, using tuples to return more than one value from a method (such as in GetFoo above) is quick and convenient, but the return value doesn’t have any inherent structure — you might do better with a struct or class type, if you’re willing to take some additional time to define it.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been looking at posts discussing SSH tunneling which sounds analogous to what
We have been discussing this at work and now I am even more confused
A friend and I have been discussing what's the best way to send large
A colleague of mine and I have been discussing how to declare variables in
On the SO blog and podcast Joel and Jeff have been discussing the, often
I've been discussing a code style issue with a friend. We have a series
Inspired by the discussion in this question . We have all been taught that
I am taking programming courses and we have been discussing Open Source and having
I have been extensively searching all over the net last night until today and
Me and my co-worker have been discussing async procedures. Example: ws.GetAllEventsAsync(123, 123); ws.GetAllEventsCompleted +=

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.