Switch y Case
#2

Puedes utilizar default: lo cual es el equivalente a un else en una condiciуn if

case 5:
{

}
default:
{
// cualquier otro
}

sin embargo, en tu caso lo mejor seria un if pues no hay operadores de mayor o menor
Reply


Messages In This Thread
Switch y Case - by Mamoru - 07.08.2016, 13:51
Respuesta: Switch y Case - by Zume - 07.08.2016, 14:31
Respuesta: Switch y Case - by Mamoru - 07.08.2016, 15:00
Re: Switch y Case - by bm0z - 08.08.2016, 11:45
Re: Switch y Case - by RIDE2DAY - 08.08.2016, 14:56
Respuesta: Switch y Case - by Zume - 08.08.2016, 23:37
Respuesta: Switch y Case - by Whyd - 09.08.2016, 09:14
Respuesta: Re: Switch y Case - by Glimma - 09.08.2016, 13:49

Forum Jump:


Users browsing this thread: 1 Guest(s)