Computer Science, asked by anmoldeepsukhra, 1 year ago

ritu has written a program in java using switch statement. when she executed the programs, the output of all the cases came together. which statement is missing in the program? help her.

Answers

Answered by Tansha
3

Ritu has not used the break statement after every case....which resulted in a fall through....



Hope this helped you......


Thnxx alot babe.......



------+--------+-+--+-+-+-+-++-+++++++++-

Answered by MAJU03
2

Ritu has not given the break statement.It helps to give the correct output and not the output of all the cases will come together

Similar questions