def pop_options(options, names):
    """Remove the given keys from options.

    Return a new dictionary with those key-value pairs.

    Args:
        options: dictionary
        names: list of keys.
    
    Returns:
        dict
    """
    new = {}
    for name in names:
        if name in options:
            new[name] = options.pop(name)
    return new
