We’re preparing your current view and syncing the latest data.
Given a list of strings, count the number of pairs (i, j) such that string j is a Caesar cipher shift of string i. A Caesar cipher shift means each character in one string is shifted by the same amount in the alphabet to get the other string. Return the total number of such pairs.
An array of strings.
An integer representing the count of valid pairs.
1 <= number of strings <= 10^5; 1 <= length of each string <= 10^3; strings consist of lowercase English letters.