human
Longest Subsequence of a String containing only Consonants | Returns true if x is consonants ..
'' Function to check whether a character  is consonants or not .
Function to find the longest subsequence which contain all consonants.
Driver code.
Function call"
How can the above be solved in Python?
assistant
#Here is code to longest Subsequence of a String containing only Consonants and the other steps required.
 def isComsomamts ( x ) :
	x = x . lower ( )
	return not ( x == ' a ' or x == ' e ' or x == ' i ' or x == ' o ' or x == ' u ' )
def longestConsonantsSubsequence ( s ) :
	answer = ' '
	n = len ( s )
	for i in range ( n ) :
		if isComsomamts ( s [ i ] ) :
			answer += s [ i ]
	return answer
s = ' geeksforgeeks '
print ( longestConsonantsSubsequence ( s ) )