Can you switch case a String?

The switch statement compares the String object in its expression with the expressions associated with each case label as if it were using the String. equals method; consequently, the comparison of String objects in switch statements is case sensitive .

Sizin İçin Seçtik  Can we use switch case inside while loop?

Leave a Reply

Your email address will not be published. Required fields are marked *