2022-02-11 12:28:36 +03:00
|
|
|
import Data.List
|
2022-03-17 21:23:47 +03:00
|
|
|
import Data.Nat
|
|
|
|
|
|
|
|
insertAtCases : List (List Nat)
|
|
|
|
insertAtCases = [
|
|
|
|
insertAt 0 9 [6, 7, 8],
|
|
|
|
insertAt 1 9 [6, 7, 8],
|
|
|
|
insertAt 3 9 [6, 7, 8],
|
|
|
|
insertAt 0 9 [6],
|
|
|
|
insertAt 1 9 [6],
|
|
|
|
insertAt 0 9 []
|
|
|
|
]
|
2022-02-11 12:28:36 +03:00
|
|
|
|
|
|
|
deleteAtCases : List (List Nat)
|
|
|
|
deleteAtCases = [
|
|
|
|
deleteAt 0 [3],
|
|
|
|
deleteAt 0 [3, 4],
|
|
|
|
deleteAt 1 [3, 4],
|
|
|
|
deleteAt 0 [3, 4, 5],
|
|
|
|
deleteAt 1 [3, 4, 5],
|
|
|
|
deleteAt 2 [3, 4, 5]
|
|
|
|
]
|
|
|
|
|
2022-03-04 02:40:18 +03:00
|
|
|
replaceAtCases : List (List Nat)
|
|
|
|
replaceAtCases = [
|
|
|
|
replaceAt 0 6 [3],
|
|
|
|
replaceAt 0 6 [3, 4],
|
|
|
|
replaceAt 1 6 [3, 4],
|
|
|
|
replaceAt 0 6 [3, 4, 5],
|
|
|
|
replaceAt 1 6 [3, 4, 5],
|
|
|
|
replaceAt 2 6 [3, 4, 5]
|
|
|
|
]
|
|
|
|
|
2022-02-11 12:28:36 +03:00
|
|
|
main : IO ()
|
2022-03-04 02:40:18 +03:00
|
|
|
main = do
|
2022-03-17 21:23:47 +03:00
|
|
|
printLn insertAtCases
|
2022-03-04 02:40:18 +03:00
|
|
|
printLn deleteAtCases
|
|
|
|
printLn replaceAtCases
|