Company: Visa fte
Difficulty: medium
Block Building Operations Given an infinite integer number line, you would like to build some blocks and obstacles on it. Specifically, you have to implement code which supports two types of operations: [1, x] - builds an obstacle at coordinate x along the number line. It is guaranteed that coordinate x does not contain any obstacles when the operation is performed. [2, x, size] - checks whether it\'s possible to build a block centered on x and extending size - 1 in each direction. For example, for size = 3 and x = 0 , it will check -2 through 2 on the number line for obstacles. Produces \"1\" if it is possible, i.e., if there are no obstacles at the specified coordinates, and produces \"0\" otherwise. Please note that this operation does not actually build the block, it only checks whether a block can be built. Given an array of operations containing both types of operations above, your task is to return a binary string representing the outputs for all [2, x, size] operations. Input F