23.02.2017 Views

Java

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

62<br />

3. sintaxis<br />

if(estaLloviendo()) {// caso true<br />

noSalgo();<br />

…<br />

// al finalizar continúa en A<br />

} else { // caso false<br />

salgo();<br />

…<br />

// al finalizar continúa en A<br />

}<br />

…<br />

// A<br />

Finalmente, podemos encadenar varios if utilizando else<br />

if(), de acuerdo a nuestras necesidades.<br />

Antes<br />

No<br />

Condición<br />

IF<br />

Sí<br />

Bloque IF<br />

Bloque ELSE<br />

Después<br />

Figura 6. En esta imagen podemos ver el diagrama de flujo<br />

correspondiente al funcionamiento de ifElse.<br />

www.redusers.com<br />

www.FreeLibros.me

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!