My solution passes the sample test case, but still gives wrong answer. I donβt get why,
I have used Lazy Propagation to solve it.
Please have a check.
Query Bits- No accepting
Post the question also, so that I can help you
It is Query Bits under the Segment Trees Problems.
Explanation
Initially the integer in binary is β000β. After first query, it becomes, 110(=6). Answer to next query comes out to be 6, i.e. β110β in decimal. After 3rd query, it becomes β100β. Answer to 4th query is 0,i.e. decimal of β0β. After 5th query, it becomes, β101β and thus answer to the last query comes out to be 5, i.e. β101β i decimal.
show me how you formed the tree in your approach. You can attach a pic in your answer