Multiple variables in switch statement in c
Posted
by Muhammad Kashif Nadeem
on Stack Overflow
See other posts from Stack Overflow
or by Muhammad Kashif Nadeem
Published on 2010-03-27T19:34:26Z
Indexed on
2010/03/27
19:43 UTC
Read the original article
Hit count: 284
How to write following statement in c using switch statement in c
int i = 10;
int j = 20;
if (i == 10 && j == 20)
{
Mymethod();
}
else if (i == 100 && j == 200)
{
Yourmethod();
}
else if (i == 1000 || j == 2000) // OR
{
Anymethod();
}
Thanks
© Stack Overflow or respective owner