Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class My(x: Int) {
- val foo = x*x
- def \ (that: Int) = this.foo + that.foo
- }
- val x = new My(10)
- val y = new My(5)
- x \ y // 75
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement