Compare cuteness

Challenge
No

Cthulhu has data on goat cuteness. You can download it. Here's some of the data:

  • "Name","Cuteness"
  • "Lino",10
  • "Johnnie",5
  • "August",9
  • "Leticia",5
  • "Andreas",10
  • "Rhonda",10

Write a program to compute the average cuteness of goats whose names begin with A-L, and goats whose names begin with M-Z. Do this for valid records only. Validity rules:

  • Goat name must be present.
  • Cuteness ratings are ints from 0 to 10.

Output:

  • First half average cuteness: 7.0
  • Second half average cuteness: 7.1

Write a subset function that works for creating both subsets.

Hints:

  • thing[0] is the first character of the string thing.
  • a < b < c < d... < l < m ... y < z.
  • def get_records_by_name(data_set, low_letter, high_letter):

Upload a zip of your project folder. The usual coding standards apply.

Attachments
Where referenced