def _make_month_test(pos, month):
    """ Returns a simple function that tests whether a string starts with
    the given month in integer format."""
    month = str(month)
    def test(xs):
        return xs[pos].startswith(month) or xs[pos].startswith('0' + month)
    return test