Skip to content

Instantly share code, notes, and snippets.

@WimJongeneel
Created December 15, 2019 10:46
Show Gist options
  • Save WimJongeneel/2289b2c668ea28bb098316e605901b42 to your computer and use it in GitHub Desktop.
Save WimJongeneel/2289b2c668ea28bb098316e605901b42 to your computer and use it in GitHub Desktop.
match-1.ts
match(1)
.with(1, v => v * 2)
.with(2, v => v * v)
.otherwise(() => -1)
.run()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment