Objectives Python Programming: An Introduction to Computer Science Chapter 2 Writing Simple Programs Python Programming, 2/e 1 Objectives To be able to understand and write…