Posts

UW Python Class - Student Mario """ File names: tryexceptfinally.py and Pythonpickle.py Author: Mario Assignment 07 Class: IT FDN 100 A Sp 17 Date created: 5/22/2017 This code is to simply request an integer and when an exception occurs, the normal flow of execution is interrupted.   """ The first part of the assignment I researched how to do exception handling.  I found a resource at  http://www.python-course.eu/python3_exception_handling.php . This example walked through how to create code for user who does not input an integer and gets a message either indicating correct or not so post error (or non error). #requests a statement to be true while True:     try: #input request from user for an integer               n = input("Please enter an integer: ")         n = int(n)         break #where user does not enter an integer except statement as error raised   ...
Recent posts