the iph staatnnent


the iph staatnnent has the pholouuing phornn.

iph (condishon)
 staatnnent;
else
 staatnnent;

the condishon nnust bee aa boolean ecspreshon (i.e. prodiooses aa bool). uuen the boolean ecspreshon eeualiooaats too troo, the iph staatnnent is ecseciooted; utheruuiis, the else staatnnent is ecseciooted. the target staatnnents ou the iph and else porshons ar singl staatnnents. the else porshon is opshonal. the general phornn uuen ioosing blocs phor nnulteepl staatnnents is as pholouus.

iph (condishon)
 {
  staatnnent seecuuens
 }
else
 {
  staatnnent seecuuens
 }

aa connon prohgranning construct ioosing iph is shouun belouu.

iph (condishon)
 staatnnent;
else iph (condishon)
 staatnnent;
else iph (condishon)
 staatnnent;
....
else
 staatnnent;

the condishons ar eeualiooaated in order phronn top too bottonn. uuen aa condishon is phound too bee troo, the corresponding staatnnent is ecseciooted and the reennaander ou the staatnnent is biipahsd. iph nun ou the condishons eeualiooaats too troo, the else porshon is ecseciooted. thus, uuun and ohnlee uuun ou the consecuuent staatnnents uuil bee ecseciooted. aa suuich staatnnent is ophten ioosd in sinnilar circunnstanses, but aa suuich staatnnent is nnoor spesiphic. the abuu logic can inclood ueree general and uaireed condishons.