human
Count maximum occurrence of subsequence in string such that indices in subsequence is in A . P . | Function to find the maximum occurrence of the subsequence such that the indices of characters are in arithmetic progression.
Frequencies of subsequence.
Loop to find the frequencies of subsequence of length 1.
Loop to find the frequencies subsequence of length 2.
Finding maximum frequency.
Driver Code"
Solution in Python:

Write me a code to count maximum occurrence of subsequence in string such that indices in subsequence is in A?
assistant
#Here is code to count maximum occurrence of subsequence in string such that indices in subsequence is in A .
 def maximumOccurrence ( s ) :
	n = len ( s )
	freq = { }
	for i in s :
		temp = " "
		temp += i
		freq [ temp ] = freq . get ( temp , 0 ) + 1
	for i in range ( n ) :
		for j in range ( i + 1 , n ) :
			temp = " "
			temp += s [ i ]
			temp += s [ j ]
			freq [ temp ] = freq . get ( temp , 0 ) + 1
	answer = - 10 ** 9
	for it in freq :
		answer = max ( answer , freq [ it ] )
	return answer
if __name__ == ' _ _ main _ _ ' :
	s = " xxxyy "
	print ( maximumOccurrence ( s ) )