Julia Language if statement with multiple branches


d = Dates.dayofweek(now())
if d == 7
    println("It is Sunday!")
elseif d == 6
    println("It is Saturday!")
elseif d == 5
    println("Almost the weekend!")
    println("Not the weekend yet...")

Any number of elseif branches may be used with an if statement, possibly with or without a final else branch. Subsequent conditions will only be evaluated if all prior conditions have been found to be false.