Driver code
str1 = " geeksforgeeks " ; NEW_LINE n = len ( str1 ) ; NEW_LINE tree = [ [ 0 for x in range ( 27 ) ] for y in range ( max ) ] ; NEW_LINE buildBIT ( tree , str1 , n ) ; NEW_LINE qType1 ( tree , 4 , ' g ' , str1 ) ; NEW_LINE qType2 ( tree , 1 , 4 , str1 ) ; NEW_LINE qType2 ( tree , 2 , 3 , str1 ) ; NEW_LINE qType1 ( tree , 10 , ' t ' , str1 ) ; NEW_LINE qType2 ( tree , 10 , 11 , str1 ) ; NEW_LINE