无标题文章

defsanitize(time_string):

if'-'intime


_string:

splitter='_'

classathletelist(list):

def__init__(self,a_name,a_dob=None,a_times=[]):

list.__init__([])

self.name=a_name

self.dob=a_dob

self.extend(a_times)

deftop3(self):

return(sorted(self)[0:3])

vera = athletelist('vera vi')

vera.append('1.31')

vera.append('1.51')

vera.append('1.21')

print(vera.top3())

你可能感兴趣的:(无标题文章)