Computer Science, asked by ashi200695, 4 months ago

list the difference between if and switch statement in java​

Answers

Answered by hellohello1235
1

Answer:

If is used when you have 3 or less than 3 either or statements or problems

Switch is basically used when there are more than 3 either or statements

IT IS CONVENIENT TO USE SWITCH INSTED OF IF TO KEEP YOUR SYNTAX SIMPLE IN THE CONDITION ABOVE

Explanation:

MARK ME BRAINLIEST

THANKS

Similar questions