중첩된 iff

코드 예제

0
0

중첩된 if...else Statement

var number = 5
// outer if statement
if (number >= 0) {

  // inner if statement
  if (number == 0) {
      print("Number is 0")
  }

  // inner else statement
  else {
      print("Number is positive");
  }
}

// outer else statement
else {
    print("Number is negative");
}
0
0

중첩된 경우 성명

if (condition) {

  if (anotherCondition) {
    // executes if both condition and anotherCondition are true
  } else {
    // executes if condition is true and anotherCondition is false
  }

} else {
  // executes if condition is false
}

다른 언어로

이 페이지는 다른 언어로되어 있습니다

Русский
..................................................................................................................
English
..................................................................................................................
Italiano
..................................................................................................................
Polski
..................................................................................................................
Română
..................................................................................................................
हिन्दी
..................................................................................................................
Français
..................................................................................................................
Türk
..................................................................................................................
Česk
..................................................................................................................
Português
..................................................................................................................
ไทย
..................................................................................................................
中文
..................................................................................................................
Español
..................................................................................................................
Slovenský
..................................................................................................................
Балгарскі
..................................................................................................................
Íslensk
..................................................................................................................