[EMAIL PROTECTED] writes:
S.D.Mechveliani writes:
As Haskell has the standard functions fst, snd to decompose (a,b),
maybe, it worths to provide also [...]
I've found some of these useful, except I named them differently:
fst3 :: (a,b,c) - a
snd3 :: (a,b,c) - b
thd3 :: (a,b,c) - c
[EMAIL PROTECTED] (Ketil Z. Malde) wrote:
I'd like a general 'nth', but of course that would restrict us to
monotyped tuples (e.g.,
nth :: Int - (a,a,...,a,a) - a
)
Under [1] you find an interesting proposal for Template Haskell.
I don't know, how far it is from beiing
Hi!
[...]
twin :: a - (a,a)
twin x = (x,x)
By using the Monad instance of ((-) a), defined in Control.Monad.Reader, one
can write join (,) for twin. (And, by the way, one can use join for functions
in several other useful ways. For example, one can write join (*) for a
squaring
Vinicius Callegari writes:
[...]
Tim, watch out, your date is in the past. You messages might not be read...
Thanks for the warning. The messages were indeed sent in the past, and took an
unusually long time to be delivered!
Apparently a few messages got queued somewhere by my MTA (perhaps
| As Haskell has the standard functions fst, snd to decompose (a,b),
| maybe, it worths to provide also
| tuple31, tuple31, tuple31,
| ...
| tuple51, tuple52, tuple53, tuple54, tuple55
|
| for the tuples of n =
As Haskell has the standard functions fst, snd to decompose (a,b),
maybe, it worths to provide also
tuple31, tuple31, tuple31,
...
tuple51, tuple52, tuple53, tuple54, tuple55
for
As Haskell has the standard functions fst, snd to decompose (a,b),
maybe, it worths to provide also
tuple31, tuple31, tuple31,
...
tuple51, tuple52, tuple53, tuple54, tuple55
for the tuples of n = 3,4,5 ?
On 16 Sep, Keith Wansbrough wrote:
I suggest calling them "pi13" or "prj13" rather than "tuple31", though.
pi1_3 or proj1_3 or select_1_3 or sel_1_3, even s_1_3 -- omitting the
"_" means sel is ambiguous (!). We should choose a scheme that can
cope with such things even if they are
Jón Fairbairn wrote (to the Haskell mailing list):
pi1_3 or proj1_3 or select_1_3 or sel_1_3, even s_1_3 -- omitting the
"_" means sel is ambiguous (!). We should choose a scheme that can
cope with such things even if they are unlikely.
I don't think pi_m_n looks right unless you