def pad_or_truncate(some_list, target_len):
    """
    This function shortens or extends a list. When it is extended, extra 0 values are added. This can be helpful to
    simulate what happens after a storm has passed.

    :param some_list: The original list of values
    :param target_len: the wanted length of the list

    :return: a list of values with length of target_len
    """
    return some_list[:target_len] + [0]*(target_len - len(some_list))