Is it possible to have a switch statement use more than one variable? i.e., something like:
Code:switch (n && nn) { case 1 && 2: cout<< "n was 1 and nn was 2." <<endl; break; case 2 && 1: cout<< "n was 2 and nn was 1." <<endl; break; default: cout<< "n wasn't 1 or 2 and neither was nn." <<endl; }



LinkBack URL
About LinkBacks



