2015 Montedio Yamagata season
2015 season | |
---|---|
Manager | |
Stadium | ND Soft Stadium Yamagata |
J1 League | 18th |
2015 Montedio Yamagata season.
J1 League
gollark: ```fsharptype Thing = | Foo of int | Bar of string | Baz of Thing listlet rec printThing t = match t with | Foo f -> sprintf "foo: %d" f | Bar s -> sprintf "bar: %s" s | Baz ts -> sprintf "[%s]" <| String.concat ", " (List.map printThing ts)```More pattern matching examples!
gollark: I was going to have `let printed` at the top then changed my mind.
gollark: Oh, yes, silly me.
gollark: ```javascriptconst printNumber = n => { switch(n) { case 0: return "zero"; //break; case 1: return "one"; //break; case 2: return "two"; //break; case 3: return "three"; //break; default: return "many"; }}```That's much longer, and uglier, especially with the breaks (not needed in this example, but generally will be).
gollark: ```fsharplet printNumber n = match n with | 0 -> "zero" | 1 -> "one" | 2 -> "two" | 3 -> "three" | _ -> "many"```
References
This article is issued from Wikipedia. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.