Skip to content

Instantly share code, notes, and snippets.

@kopos
Created November 5, 2013 12:05
Show Gist options
  • Save kopos/7318098 to your computer and use it in GitHub Desktop.
Save kopos/7318098 to your computer and use it in GitHub Desktop.
scala tests
// Use as sum(4, 5)
// Use as sum(sum(4, 5), sum(1, 2))
def sum(x: Int, y: Int): Int = {
x + y;
}
// Use as sum(4, 5)
// Use as sum(sum(4, 5), sum(1, 2))
def sum = (x: Int, y: Int) => { x + y; }
@kopos
Copy link
Author

kopos commented Nov 5, 2013

@todo: Need to look at method, function and procedure

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment