Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def score(self, photo):
- common_tags = len(set(photo.tags).union(set(self.tags)))
- return min(len(self.no_tags) - common_tags, common_tags, photo.no_tags - common_tags)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement