java | operator is for what?

后端 未结 8 1213
故里飘歌
故里飘歌 2021-01-25 11:14

What is the output of this java code and why ?

 int a = 5 | 3 ;
 System.out.println(a);
8条回答
  •  面向向阳花
    2021-01-25 11:53

    That's the bitwise-or operator.

    http://leepoint.net/notes-java/data/expressions/bitops.html

提交回复
热议问题