Create Binary Index Tree (1-D)

cpp code for binary ondex tree(1-D) with queries