Skip to content

Instantly share code, notes, and snippets.

@kunigami
Last active June 11, 2018 05:31
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kunigami/5606da7fc00928f815a40d1186dd0471 to your computer and use it in GitHub Desktop.
Save kunigami/5606da7fc00928f815a40d1186dd0471 to your computer and use it in GitHub Desktop.
let sum arr = Js.Array.reduce (+) 0 arr
let () = Js.log (sum [| 10; 20; 30 |])
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment