Complex conditions of if/else statements in Swift
Forums:
let A = 3
let B = 5
let C = 7
if (C >= A && C >= B) {
//nothing is larger than C.
}
if (!(A >= B || A >= C)) {
//A is the smallest
}
- Log in to post comments
let A = 3
let B = 5
let C = 7
if (C >= A && C >= B) {
//nothing is larger than C.
}
if (!(A >= B || A >= C)) {
//A is the smallest
}