在C++中,switch語句的語法: switch (變數){ case 數字或字元: /* 程式碼*/ break; default: /* 程式碼*/. switch 會依序拿代入的變數來和每個 case 進行比對,
確定! 回上一頁