June 2018
Beginner
722 pages
18h 47m
English
You have also seen the usage of separators () (parentheses) to keep the list of method parameters in the method definition and method invocation:
void someMethod(int i) { //... String s = anotherMethod(); //...}
They are also used in control-flow statements (see Chapter 10, Control Flow Statements):
if(i == 2){ //...}
During typecasting (see the Primitive types and literals section), they are put around the type:
long v = 23;int i = (int)v;
As for setting the precedence of an execution (see Chapter 9, Operators, Expressions, and Statements), you should be familiar with it from basic algebra:
x = (y + z) * (a + b).
Read now
Unlock full access