You are given an array A of length N. You are also given Q tasks.
Each task is of the following type:
L R V: Apply the bitwise-and operator with V for all AiwhereL≤i≤R
You need to print the array after performing all the tasks.
Input format
Output format
Print the final array after performing all the Q tasks.
Constraints
1≤N≤105
1≤Q≤2∗105
1≤Ai,V≤109
1≤L≤R≤N
After first task, the array will be {4,4,4,7,7}.
After second task, the array will be {4,4,4,6,6}.