add bkdr hash function