The website uses cookies to optimize your user experience. Using this website grants us the permission to collect certain information essential to the provision of our services to you, but you may change the cookie settings within your browser any time you wish. Learn more
I agree
Summary | 10 Annotations
You start and end a raw string with three double quotation marks in a row (""").
2018/10/02 13:54
To use this method, put a pipe character (|) at the front of each line, and then call stripMargin on the whole string:
2018/10/02 13:54
Symbol literals
2018/10/02 13:57
You can use any method in operator notation
2018/10/02 14:00
whenever you call a method that takes multiple arguments using operator notation, you have to place those arguments in parentheses.
2018/10/02 14:01
The only identifiers that can be used as prefix operators are +, -, !, and ~.
2018/10/02 14:04
The convention is that you include parentheses if the method has side effects, such as println(), but you can leave them off if the method has no side effects, such as toLowerCase invoked on a String
2018/10/02 14:05
Postfix operators are methods that take no arguments, when they are invoked without a dot or parentheses
2018/10/02 14:06
In Scala, you can leave off empty parentheses on method calls
2018/10/02 14:06
This is accomplished with a very simple rule: first check the left side for null, and if it is not null, call the equals method. Since equals is a method, the precise comparison you get depends on the type of the left-hand argument.
2018/10/02 14:09