Syntax
switch(expression)
{
illustration condition_variable-1:
statements;
break;
illustration condition_variable-2:
statements;
break;
illustration condition_variable-3:
statements;
break;
--------------
--------------
--------------
illustration condition_variable-n:
statements;
break;
default:
statements;
}
Example
a=3;
switch(a)
illustration 1:
{
alert("One");
break;
illustration 2:
alert("Two");
break;
illustration 3:
alert("Three");
break;
default:
alert("no status matched");
}
Flow Chart
Example Program:- (Editor)
Editor is Loading...
Advertisement
Tags:
switch illustration contention inwards allinworld99, switch inwards javascript, illustration contention inwards javascript,switch too illustration inwards allinworld99 javascript.
Tidak ada komentar:
Posting Komentar