✏️ Explanatory Question

Variables used in a switch statement can be used with which datatypes?

👁 986 Views
📘 Detailed Answer
💡

Answer with Explanation

Variables used in a switch statement can only be a string, enum, byte, short, int, or char.