Compute Prefix Hash and Suffix Hash Arrays
computePrefixHash ( str , n , prefix , power ) ; computeSuffixHash ( str , n , suffix , power ) ; Query q [ ] = { { 0 , 10 } , { 5 , 8 } , { 2 , 5 } , { 5 , 9 } } ; int m = sizeof ( q ) / sizeof ( q [ 0 ] ) ; queryResults ( str , q , m , n , prefix , suffix , power ) ; return ( 0 ) ; }