Page 183 -
P. 183

comprehending data



                        Test Drive




                       Let’s see if this improves your output in any way. Make the necessary amendments to your code and
                       run it.














                                                         Here’s the updates
                                                          to the code.                   The data is not at all
                                                                                          But look at THIS!

                                                                                         sorted…which is, like,
                                                                                         weird.















             Look at this: 2-55 is
             coming BEFORE 2.18…now
             that is weird.                Hey, it looks like your data values are
                                           not uniform. Is the problem with all those
                                           periods, dashes, and colons?



                                                      Yes. The minute and seconds separators are
                                                      confusing Python’s sorting technology.
                                                      When recording his athletes’ times in each of their files, Coach
                                                      Kelly sometimes used a different character to separate minutes
                                                      from seconds. It looks like you need to fix your data.


                                                                                      you are here 4    147
   178   179   180   181   182   183   184   185   186   187   188