human
Check if a word is present in a sentence | Function that returns true if the word is found.
To convert the word in uppercase.
To convert the complete sentence in uppercase.
To break the sentence in words.
To store the individual words of the sentence.
Compare the current word with the word to be searched.
Driver code"
Solution in Python:
 Give me a code to check if a word is present in a sentence and the other steps required?
assistant
#Here is code to check if a word is present in a sentence and the other steps required.
 def isWordPresent ( sentence , word ) :
	word = word . upper ( )
	sentence = sentence . upper ( )
	s = sentence . split ( ) ;
	for temp in s :
		if ( temp == word ) :
			return True ;
	return False ;
if __name__ == " _ _ main _ _ " :
	s = " Geeks ▁ for ▁ Geeks " ;
	word = " geeks " ;
	if ( isWordPresent ( s , word ) ) :
		print ( " Yes " ) ;
	else :
		print ( " No " ) ;