-

   rss_rss_hh_new

 - e-mail

 

 -

 LiveInternet.ru:
: 17.03.2011
:
:
: 51

:


[ ] Java

, 09 2017 . 19:17 +
, Java. , , , . , . , . , -, , , , Java- . , , .

, Java operator, operation, operand statement. , operator . , : / . , . , operator operation, : Operators are special symbols that perform specific operations on one, two, or three operands, and then return a result. .

statement. : , , , .

: Statements are roughly equivalent to sentences in natural languages. A statement forms a complete unit of execution .. , . statements.

, , , . . , ( - ?) switch:

        switch (choice) {
            case 1: 
                     . . . .
                     break;
            case 2: 
                     . . . .
                    break;
            case 3: 
                     . . . .
                     break;
            case 4: 
                     . . . .
                     break;
            default:
                     // 
                     break;
        }

: switch, choice, case n ( case n), default, break? , , :
case, 1 choice, break switch.
.
1 choice
, , , . . statement , . , :

switch statement;
choice expression;
case switch label;
n case constant;
break statement;

->

. , , . , Java 1999 . , , . , , , . , 2015 , , . -, , , . , , . operator , statement , ..

, , , , , . , , , , , , , . Java? , . , .
Original source: habrahabr.ru (comments, light).

https://habrahabr.ru/post/330624/

:  

: [1] []
 

:
: 

: ( )

:

  URL