Python String – find() method
This method in python finds the first occurrence and returns the index of the first character of the value. If not found it returns -1. Syntax: string.find(value, starting_index, ending_index) Example 1: s = “CodeWindow offers IT related news” x = s.find(“IT”) print(x) Output: 18 Explanation: The word “IT” is present in the string starting from […]