I have a list of 10-tuples in Haskell and I want to get nth tuple from that list of tuples. But as I saw, only length function worked with that list. head, tail or !! functions didn't work. Can you tell me what should I do? The tuples are composed of integers and strings.
For example when I try this :
tail [(3,5,"String1","String2","String3","String4","String5","String6","String7","String8"),(3,5,"String1","String2","String3","String4","String5","String6","String7","String8"),(3,5,"String1","String2","String3","String4","String5","String6","String7","String8")]
I get this error message from hugs:
ERROR - Cannot find "show" function for:
*** Expression : tail [(3,5,"String1","String2","String3","String4","String5","String6","String7","String8"),(3,5,"String1","String2","String3","String4","String5","String6","String7","String8"),(3,5,"String1","String2","String3","String4","String5","String6","String7","String8")]
*** Of type : [(Integer,Integer,[Char],[Char],[Char],[Char],[Char],[Char],[Char],[Char])]
See Question&Answers more detail:
os