📜  从列表中删除第 n 个元素 haskell 代码示例

📅  最后修改于: 2022-03-11 14:53:35             🧑  作者: Mango

代码示例1
deleteN :: Int -> [a] -> [a]
deleteN _ []     = []
deleteN i (a:as)
   | i == 0    = as
   | otherwise = a : deleteN (i-1) as