Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
7
Task/Reverse-a-string/Ela/reverse-a-string-1.ela
Normal file
7
Task/Reverse-a-string/Ela/reverse-a-string-1.ela
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
reverse_string str = rev len str
|
||||
where len = length str
|
||||
rev 0 str = ""
|
||||
rev n str = toString (str : nn) +> rev nn str
|
||||
where nn = n - 1
|
||||
|
||||
reverse_string "Hello"
|
||||
2
Task/Reverse-a-string/Ela/reverse-a-string-2.ela
Normal file
2
Task/Reverse-a-string/Ela/reverse-a-string-2.ela
Normal file
|
|
@ -0,0 +1,2 @@
|
|||
open string
|
||||
fromList <| reverse <| toList "Hello" ::: String
|
||||
Loading…
Add table
Add a link
Reference in a new issue