<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def expand_entries(entries, ignore_xs=None):
 """Turn all Xs which are not ignored in all entries into ``0`` s and ``1`` s. For example:: True Note that the ``X`` in the LSB was retained because it is common to all entries. Any duplicated entries will be removed (in this case the first and second entries will both match ``0000``, so when the second entry is expanded only one entry is retained):
: True .. warning:: It is assumed that the input routing table is orthogonal (i.e., there are no two entries which would match the same key). If this is not the case, any entries which are covered (i.e. unreachable) in the input table will be omitted and a warning produced. As a result, all output routing tables are guaranteed to be orthogonal. Parameters The entries to expand. Other Parameters ignore_xs : int Mask of bits in which Xs should not be expanded. If None (the default) then Xs which are common to all entries will not be expanded. Yields ------ :py:class:`~rig.routing_table.RoutingTableEntry` Routing table entries which represent the original entries but with all Xs not masked off by `ignore_xs` replaced with 1s and 0s. """

    # Find the common Xs for the entries
    if ignore_xs is None:
        ignore_xs = get_common_xs(entries)

    # Keep a track of keys that we've seen
    seen_keys = set({})

    # Expand each entry in turn
    for entry in entries:
        for new_entry in expand_entry(entry, ignore_xs):
            if new_entry.key in seen_keys:
                # We've already used this key, warn that the table is
                # over-complete.
                warnings.warn("Table is not orthogonal: Key {:#010x} matches "
                              "multiple entries.".format(new_entry.key))
            else:
                # Mark the key as seen and yield the new entry
                seen_keys.add(new_entry.key)
                yield new_entry