n = int(input()) a = list(map(int, input().split())) x = int(input()) for i in range(n): if a[i] > 100: a[i] = x print(*a)