Today we continue reviewing the whitepaper - the chutes and ladders of customer identity from Gigya which is a leader in Customer Identity and Access Management Industry. The title uses an analogy of a well-known game. This is a whitepaper that introduces the delights and the pitfalls in customer experience with identity. We read about the personalization experience from the beginning and the need for a lighter touch. More visitors register themselves when they see a value and an easy way in. Most of them already know the benefits of setting up an account such as keeping track of history, making purchases with a single click and so on. The effort involved in setting it up varies if its online or via the download of an app. The process of login can be replaced with techniques that are not only hard to hack but also offer superior behaviors risk-based authentication which can be used to combat fraud. Multiple factors of authentication can be added included one time passcodes. Also customer data can be collected over time and the profile built up on a continuous basis. This data can also be shared or synchronized with downstream marketing, sales and services based on compliance with privacy and industry standards.
There is an interesting take on CIAM Solutions introduced earlier. They take first party data of the customer as cash. Its value is immediate and most reliable. This is why CIAM Solutions manage their own data while also allowing information to flow downstream to other parties. There is transparency required by virtue of the data and integration between systems should be facilitated but these systems realize the importance of first party data.
#codingexercise
count palindrome substrings in a string.
We mentioned the brute force way is to enumerate all substring and check for palindrome. This is also similar to using each letter as the center of a palindrome candidate and expanding it in both directions for even and odd length palindrome.
An alternative would be to find disjoint longest palindromes in the string by expanding the string one character at a time. Care must be taken to count the inner palindromes of a palindrome. Finally we know that the lengths of the palindrome up to those found to a given center are also palindromic. Therefore we look for the next center based on the lengths we have found already. The suggestion is that the lengths array we construct will have values similar to the palindromic nature of Pascal's triangle.
Therefore the algorithm is:
Initialize the lengths array to the number of possible centers
Set the current center to the first center
Loop while the current center is valid:
Expand to the left and right simultaneously until we find the largest palindrome around this center
Fill in the appropriate entry in the longest palindrome lengths array
Iterate through the longest palindrome array backwards and fill in the corresponding values to the right of the entry for the current center until an unknown value (because we don't have sufficient elements in the string to make an interpretation on the length) is encountered.
Set the new center to the index of this unknown value
Return the lengths array
since this problem of counting palindrome has overlapping Subproblems in the range i to j of the string, we can also use memoization and dynamic programming. By using the lengths array and Pascal triangle, we can also get counts directly
There is an interesting take on CIAM Solutions introduced earlier. They take first party data of the customer as cash. Its value is immediate and most reliable. This is why CIAM Solutions manage their own data while also allowing information to flow downstream to other parties. There is transparency required by virtue of the data and integration between systems should be facilitated but these systems realize the importance of first party data.
#codingexercise
count palindrome substrings in a string.
We mentioned the brute force way is to enumerate all substring and check for palindrome. This is also similar to using each letter as the center of a palindrome candidate and expanding it in both directions for even and odd length palindrome.
An alternative would be to find disjoint longest palindromes in the string by expanding the string one character at a time. Care must be taken to count the inner palindromes of a palindrome. Finally we know that the lengths of the palindrome up to those found to a given center are also palindromic. Therefore we look for the next center based on the lengths we have found already. The suggestion is that the lengths array we construct will have values similar to the palindromic nature of Pascal's triangle.
Therefore the algorithm is:
Initialize the lengths array to the number of possible centers
Set the current center to the first center
Loop while the current center is valid:
Expand to the left and right simultaneously until we find the largest palindrome around this center
Fill in the appropriate entry in the longest palindrome lengths array
Iterate through the longest palindrome array backwards and fill in the corresponding values to the right of the entry for the current center until an unknown value (because we don't have sufficient elements in the string to make an interpretation on the length) is encountered.
Set the new center to the index of this unknown value
Return the lengths array
since this problem of counting palindrome has overlapping Subproblems in the range i to j of the string, we can also use memoization and dynamic programming. By using the lengths array and Pascal triangle, we can also get counts directly
No comments:
Post a Comment