--%>

Explain Switch statement

Switch statement: It is a selection statement in which the value of an arithmetic expression {expression!arithmetic} is compared for the match alongside different case labels. When no match is found, the optional default label is chosen For example:

    switch(choice){
         case 'q':
             quit();
             break;
         case 'h':
             help();
             break;
         ...
         default:
             System.out.println("Unknown command: "+choice);
             break;
    }

   Related Questions in Programming Languages

  • Q : Explain Decrement operator Decrement

    Decrement operator: It is an operator (--) which adds one to its operand. This has two forms: pre-decrement (--x) and post-decrement (x--). In its pre-decrement form, the outcome of the expression is the value of its argument subsequent to the decreme

  • Q : Explain Throws clause Throws clause :

    Throws clause: It is a clause in a method header pointing that one or additional exceptions will be propagated from this technique. For example:    public int find(String s) throws NotFoundExc

  • Q : Define the reasons of Process Handle

    Define the reasons of Process Handle Table.

  • Q : What is Syntax error Syntax error: It

    Syntax error: It is an error detected by the compiler throughout its parsing of a program. The syntax errors generally result from mis-ordering symbols in statements and expressions. Missing curly semicolons and brackets are general illustrations of s

  • Q : State the term XHTML State the term

    State the term XHTML?

  • Q : What is Reduce Concurrency Reduce

    Reduce Concurrency: From a model-checking perspective, the searched state space consists of all possible thread-state combinations, which implies that the level of concurrency has the biggest impact on state space size. As a consequence, reducing conc

  • Q : Explain the term Test Fusion Report of

    Explain the term Test Fusion Report of QTP?

  • Q : Who developed Extensible Hyper-Text

    Who developed Extensible Hyper-Text Markup Language? Answer: XHTML (Extensible Hyper-Text Markup Language) was developed by W3C HTML Working Group along with Steven

  • Q : What do you mean by process What do you

    What do you mean by the term process? Illustrate briefly.

  • Q : Explain Return type Return type : It is

    Return type: It is the declared type of a method, appearing instantly before the method name, like void in     public static void main(String[] args)    or Point[] in