Computer Science, asked by abhinavabhinav9278, 4 months ago

use switch statement for the following program snippet

if (a==10)
c=a+2;
if (a==20)
c=a+3;
if (a==60)
c=a+10;​

Answers

Answered by MuhammadSameer74
2

Answer:

switch(a)

{

  case 10:

         c = a + 2;

         break;

  case 20:

         c = a + 3

         break;

   case 60:

         c = a + 10;

         break;

   default;

         break;

}

Explanation:

This is the right way to write this program for the switch

Answered by FDSGA
1

Answer:

Explanation:

MALAYALI ANO

Similar questions