<div dir="ltr">Nan, generally speaking (e.g., in maths) tuples can contain any number of elements. Haskell specifically disallows one-tuples because of the ambiguity in parsing them. Instead, (expr) is just evaluated as expr. On the other hand, it does allow (), which is a zero-tuple. Haskell's compilers also impose an upper bound on the practical size of a tuple (for modern GHC, that's 61, as Max mentioned) but that isn't a restriction of the Haskell language itself. If you want, you can consider Identity a to be a one-tuple, but it obviously doesn't use tuple syntax.<div><br></div><div>As a side note, a 1-tuple is occasionally called a monad in other disciplines, while a monad is actually defined as a triple (a three-tuple) in maths. None of that is relevant to Haskell though.</div></div><br><div class="gmail_quote"><div dir="ltr">On Thu, Feb 25, 2016 at 7:14 AM Max Voit <<a href="mailto:max.voit%2Bmlhb@with-eyes.net">max.voit+mlhb@with-eyes.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">On Thu, 25 Feb 2016 07:49:56 +0800<br>
Nan Xiao <<a href="mailto:xiaonan830818@gmail.com" target="_blank">xiaonan830818@gmail.com</a>> wrote:<br>
<br>
> Rein referred "A tuple can have any number of elements", while Graham<br>
> referred "There's no "one-ple", or 1-tuple, in Haskell.". So which one<br>
> is right? The tuple at least contains 2 elements?<br>
<br>
There is no one-tuple; however, there's a zero-tuple. Also no arbitrary<br>
number of tuple elements allowed, due to definition (we're at 61 for<br>
some reason). Refer to<br>
<br>
<a href="http://hackage.haskell.org/package/ghc-prim-0.4.0.0/docs/GHC-Tuple.html" rel="noreferrer" target="_blank">http://hackage.haskell.org/package/ghc-prim-0.4.0.0/docs/GHC-Tuple.html</a><br>
<br>
best, Max<br>
_______________________________________________<br>
Beginners mailing list<br>
<a href="mailto:Beginners@haskell.org" target="_blank">Beginners@haskell.org</a><br>
<a href="http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners" rel="noreferrer" target="_blank">http://mail.haskell.org/cgi-bin/mailman/listinfo/beginners</a><br>
</blockquote></div>