Boyer Moore algorithm is used for pattern searching inside a string.It follows a set of rules when a mismatch occurs between the pattern and the string.The algorithm starts searching from the rightmost character in the string.If a mismatch occurs, it either skips the whole word in the string or skips until a character in the pattern matches a character in the string.