Menu BAR

FEEL FREE TO ASK ANY PROGRAM and please mention any error if you find it

1 Jan 2024

Node js program - IF ELSE IF example

# Node js program using if else if statement

var a = 'route 1';

if (a === 'route 1'){
    console.log ('Route is 1');
}else if ( a === 'route 2')  {
     console.log ('Route is 2');
}else {
    console.log ( 'No Route');
}


## When you run this program
## Output will be - 
Route is 1

No comments:

Post a Comment