我在 Haskell 中有一个 10 元组的列表,我想从该元组列表中获取第 n 个元组。但正如我所见,只有长度函数适用于该列表。头,尾或!功能不起作用。你能告诉我我该怎么做吗?元组由整数和字符串组成。例如,当我尝试这个时:
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")]
我从拥抱中收到此错误消息:
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])]