Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
4
Task/Palindrome-detection/Ela/palindrome-detection-1.ela
Normal file
4
Task/Palindrome-detection/Ela/palindrome-detection-1.ela
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
open list string
|
||||
|
||||
isPalindrome xs = xs == reverse xs
|
||||
isPalindrome <| toList "ingirumimusnocteetconsumimurigni"
|
||||
4
Task/Palindrome-detection/Ela/palindrome-detection-2.ela
Normal file
4
Task/Palindrome-detection/Ela/palindrome-detection-2.ela
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
reverse = foldl (flip (::)) (nil xs)
|
||||
|
||||
foldl f z (x::xs) = foldl f (f z x) xs
|
||||
foldl _ z [] = z
|
||||
Loading…
Add table
Add a link
Reference in a new issue