<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def breeding_male_location_type(self):
 """This attribute defines whether a male's current location is the same as the breeding cage to which it belongs. This attribute is used to color breeding table entries such that male mice which are currently in a different cage can quickly be identified. The location is relative to the first breeding cage an animal is assigned to."""

        try:
            self.breeding_males.all()[0].Cage
            if int(self.breeding_males.all()[0].Cage) == int(self.Cage):
                type = "resident-breeder"
            else:
                type = "non-resident-breeder"                
        except IndexError:
            type = "unknown-breeder"
        except ValueError:
            type = "unknown-breeder"
        return type