Home > Back-end >  K * (k); Why didn't () in the content inside is first
K * (k); Why didn't () in the content inside is first

Time:09-20

The class Test01 {
Public static void main (String [] args) {
Int k=2;
//k *=+ + k;
K=k * (+ + k);
System. The out. Println (k);
}
}

The running result is: 6.
Is to calculate the value of k "2", then the + + k value "3", then 2 * 3 get 6.

But () is not a higher priority, why not to calculate (a) + + k?

CodePudding user response:

no one,,
  • Related