Tag Archives: Pattern Count

HackerRank : Week of Code 33 – Transform to Palindrome

Transform to Palindrome: Hackerrank The Orion alphabet system consists of letters, denoted by the integers from to . The Orion letter is denoted by the integer . Some Orion letters can be transformed to other Orion letters. A transformation is denoted by a pair of two Orion letters, . Using this transformation, you can replace letter with letter… Read More »

HackerRank : Week of Code 33 – Pattern Count

Pattern Count: Hackerrank A string s contains many patterns of the form 1(0+)1 where (0+) represents any non-empty consecutive sequence of 0 ‘s. The patterns are allowed to overlap. For example, consider string “1101001”, we can see there are two consecutive sequences “1(0)1” and “1(00)1” which are of the form  1(0+)1. You have to answer q queries, each containing a string s. For… Read More »