Derek Wong's blog. A combination of images and thoughts from a software engineer in southern California.
© 2007 - 2021. All rights reserved.
The problem with this code is there are too many break statements!
def sleep(person, baby): start_time = getTime() while person.isAsleep(): time = getTime() if start_time.add(MINUTES, 180) >= time: break else if baby.isCrying() break def __main__(): while derek.isAlive(): if not areThingsToDo(): sleep(derek, derek.getChild());