introduction to python for complete description of idlesee branching programs the kinds of computations we have been looking at thus far are called straightline programs they execute one statement after another in the order in which they appearand stop when they run out of statements the kinds of computations we can describe with straight-line programs are not very interesting in factthey are downright boring branching programs are more interesting the simplest branching statement is conditional as depicted in figure conditional statement has three partsa testi an expression that evaluates to either true or falsea block of code that is executed if the test evaluates to trueand an optional block of code that is executed if the test evaluates to false after conditional statement is executedexecution resumes at the code following the statement figure flow chart for conditional statement in pythona conditional statement has the form if boolean expressionblock of code elseblock of code in describing the form of python statements we use italics to describe the kinds of code that could occur at that point in program for exampleboolean expression indicates that any expression that evaluates to true or false can follow the reserved word ifand block of code indicates that any sequence of python statements can follow else