<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _pack_people(people):
 """ Pack people into a network transmittable format :param people: People to pack :type people: list[paps.people.People] :return: The packed people :rtype: str """

        res = bytearray()
        bits = bytearray([1])

        for person in people:
            bits.extend(person.to_bits())
        aByte = 0

        for i, bit in enumerate(bits[::-1]):
            mod = i % 8
            aByte |= bit << mod
            if mod == 7 or i == len(bits) - 1:
                res.append(aByte)
                aByte = 0
        return struct.pack(APPUpdateMessage.fmt.format(len(res)), *res[::-1])