Another ICPC String Problem#10825

Another ICPC String Problem (Editorial)

Let's keep bitsets , where corresponding bitset has ones only at positions where his letter is present. Updating these bitsets after queries of type is trivial, let's see how to deal with queries of type .

Suppo