Switch hakkında soru

switch ve caseyi iki tane değişken ile yapabilir miyim?
switch(denem){
case ‘a’:
System.out.print(" 1a");

Ne yapacağına göre iç içe switch kullanman gerekebilir.

final int s1Value = 0;
final int s2Value = 0;
final String s1 = "a";
final String s2 = "g";

switch (s1 + s2 + s1Value + s2Value){
    case "ag00": return true;
    default: return false;
}
1 Beğeni