Created
September 11, 2018 22:06
-
-
Save dschinkel/a6a900ebd9c35db919775d9bb7540214 to your computer and use it in GitHub Desktop.
Elm - Basics - Example
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
myAnswerArray = | |
Array.fromList ["S"] | |
|> Array.set 5279 "S" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
viewNames1 names = | |
String.join ", " (List.sort names) | |
viewNames2 names = | |
names | |
|> List.sort | |
|> String.join ", " | |
- (arg |> func) is the same as (func arg) | |
- Just keep repeating that transformation! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment