I've been working through Cocoa Programming for Mac OS X for dummies and I'm at one point where you have to work with a pop up menu, and part of the code is...
And so on
My question is, what exactly does the "break;" do? I'm stumped with this, I couldn't find it in the documentation.
Also, what exactly is the "switch" and "case" for.
Code:
switch (operation) {
case 0:
answer = num1 + num2;
break;
case 1:
answer = num1 - num2;
break;
And so on
My question is, what exactly does the "break;" do? I'm stumped with this, I couldn't find it in the documentation.
Also, what exactly is the "switch" and "case" for.