In a switch statement, does it matter if I put the default condition at the top or bottom (or anywhere in between)?

John Mitchell

You can put the default: labeled clause anywhere you can put any of the switch's cases. In fact, you don't have to specify a default case at all.

0 Comments  (click to add your comment)
Comment and Contribute

 

 

 

 

 


(Maximum characters: 1200). You have 1200 characters left.

 

 

About | Sitemap | Contact