<commit_before>

class Prepare(object):
    """
    Prepare the champions for the battle!

    Usage:
        hero = Prepare(name="Aragorn", base_attack=100, base_hp=100)
    or like this:
        aragorn = {"name": "Aragorn", "base_attack": 100, "base_hp": 100}
        hero = Prepare(**aragorn)
    """
    def __init__(self, name, base_attack, base_hp):
        self.name = name
        self.base_attack = base_attack
        self.base_hp = base_hp

    @property
    def status(self):
        return self.__dict__

    def attack(self, foe):
        if not isinstance(foe, Prepare):
            raise TypeError('foe should be a Prepare object')

        if foe.base_hp <= 0:
            raise Exception('foe is already dead! Stop hit him!')

        foe.base_hp = foe.base_hp - self.base_attack

        if foe.base_hp <= 0:
            print 'foe is dead.'
        return foe.base_hp<commit_msg>Create a collect method for get droppable items<commit_after>class Prepare(object):
    """
        Prepare the champions for the battle!
    """
    def __init__(self, name, base_attack, base_hp):
        self.name = name
        self.base_attack = base_attack
        self.base_hp = base_hp

    @property
    def status(self):
        return self.__dict__

    def attack(self, foe):
        if not isinstance(foe, Prepare):
            raise TypeError('foe should be a Prepare object')

        if foe.base_hp <= 0:
            raise Exception('foe is already dead! Stop hit him!')

        foe.base_hp = foe.base_hp - self.base_attack

        if foe.base_hp <= 0:
            print 'foe is dead.'
        return foe.base_hp

    def collect(self, foe):
        if not isinstance(foe, Prepare):
            raise TypeError('foe should be a Prepare object')
        pass
{'fraction_non_alphanumeric': 0.09864712514092447, 'fraction_numerical': 0.009019165727170236, 'mean_word_length': 2.1753130590339893, 'pattern_counts': {'":': 3, '<': 7, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5865234', 'n_tokens_mistral': 586, 'n_tokens_neox': 536, 'n_words': 161}