def count_increased_part2(values):
    """
    Count how many measurements increased in a three-measurement sliding window

    :param values: List of values
    :returns: Number of measurements that increased in a three-measurement sliding window
    """
    # how many measurements increased in three-measurement sliding window
    increased = 0
    for i in range(2, len(values) - 1, 1):
        # print(str(values[i - 2]) + ", " + str(values[i - 1]) + ", " + str(values[i]))
        # print(str(values[i - 1]) + ", " + str(values[i]) + ", " + str(values[i + 1]) + "\n")
        window1 = values[i - 2] + values[i - 1] + values[i]
        window2 = values[i - 1] + values[i] + values[i + 1]
        if window2 > window1:
            increased += 1
    return increased