#include <iostream> using namespace std; int main() { enum rank { first, //0 second, //1 third //2 }; int nRank = 2; switch (nRank) { case first: cout<<"q"; break; case second: cout<<"w"; break; case third: cout<<"e"; break; default: break; } return 0; }