Last active
August 3, 2016 20:03
-
-
Save BensonMuriithi/cbd516f7056503a8b33e931ef916fbe1 to your computer and use it in GitHub Desktop.
My solution for 'Max of Three' exercise on practicepython.org ->http://www.practicepython.org/exercise/2016/03/27/28-max-of-three.html
This file contains hidden or 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
def whosmax(*args): | |
start = 0 | |
limit = len(args) | |
i = 1 | |
while i < limit: | |
if args[start] < args[i]: start = i | |
i += 1 | |
return args[start] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment