as simple examplea robot controller might have the following logicif door is closedopen dooradvancenotice that the final commandadvance)is not indented and therefore not part of the conditional body it will be executed unconditionally (although after opening closed doorwe may nest one control structure within anotherrelying on indentation to make clear the extent of the various bodies revisiting our robot examplehere is more complex control that accounts for unlocking closed door if door is closedif door is lockedunlock dooropen dooradvancethe logic expressed by this example can be diagrammed as traditional flowchartas portrayed in figure false door is closed true false door is locked true unlock dooropen dooradvancefigure flowchart describing the logic of nested conditional statements