This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" A simple script to calculate the diference within two courses """ | |
def course_delta(c1, c2): | |
""" Calculate the diference within two consecutive courses """ | |
if c2 < c1: | |
# The function expects that c2 is always greater than c1 | |
temp = c2 | |
c2 = c1 # switch the values of c1 and c2 | |
c1 = temp | |