elseserving "belseif random(probbscoreb scoreb elseserving "areturn scoreascoreb def gameover(ab) and represent scores for racquetball game returns true if the game is overfalse otherwise return == or == def printsummary(winsawinsb)prints summary of wins for each player winsa winsb print("\ngames simulated:"nprint("wins for { ({ : %})format(winsawinsa/ )print("wins for { ({ : %})format(winsbwinsb/ )if __name__ ='__main__'main(you might take notice of the string formatting in printsummary the type specifier is useful for printing percentages python automatically multiplies the number by and adds trailing percent sign summary of the design process you have just seen an example of top-down design in action now you can really see why it' called top-down design we started at the highest level of our structure chart and worked our way down at each levelwe began with general algorithm and then gradually refined it into precise code this approach is sometimes called step-wise refinement the whole process can be summarized in four steps express the algorithm as series of smaller problems develop an interface for each of the small problems detail the algorithm by expressing it in terms of its interfaces with the smaller problems repeat the process for each smaller problem top-down design is an invaluable tool for developing complex algorithms the process may seem easysince 've walked you through it step by step when you first try it out for yourself