Gmail 57m eft ALL 1 ▸ YouTube 98°F Sunny 12kaiaq3/questions/692ardbbm1j BETA Can't read the text? Switch theme Maps N El
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am
Gmail 57m eft ALL 1 ▸ YouTube 98°F Sunny 12kaiaq3/questions/692ardbbm1j BETA Can't read the text? Switch theme Maps N El
Gmail 57m eft ALL 1 ▸ YouTube 98°F Sunny 12kaiaq3/questions/692ardbbm1j BETA Can't read the text? Switch theme Maps N Electrical and Comp... 2. Palindrome Subsequences Note For a string s which consists only of characters '0' and '1', find the number of subsequences of length 5 which are palindromes. As the answer can be really big, return the answer mod (10⁹ + 7). • A palindrome is a string that reads the same backward as forward. Example S="0100110" Classes • A subsequence is a sequence that can be derived from the given sequence by deleting zero or more elements without changing the order of the remaining elements. • Two subsequences are considered different if the indices of the string that forms the subsequences are different. Using 1-based indexing, the 5 subsequences are • indices (1, 2, 3, 6, 7)-> 01010 wwww.hackerrank.com/test/72df2kaiaq3/questions/692ardbbm1j Zo