In my CS course a couple semesters ago at college, my professor stated that you can make a very clever iterative construct using switch and continue statements. He stated that when a continue statement was placed inside of a switch construct, and that continue statement was executed, it would go back up to the top of the switch statement and re-evaluate the switch.
This intrigued me, as I have been programming in C/C++ for almost 6 years now and have never thought of doing such a thing, or seen anyone else something like that.
But I thought it would be pretty cool to make an iterative switch statement using continue statements instead of break statements, so I decided to try it out. Unfortunatley it doesnt seem to work. So far I have tried it on gcc, g++, and Turbo C++ and none of them like it.
Should I email my professor and tell him he was utterly wrong?