You need to find the first or last occurrence of a search string within a message.
message = "This is a test string. This has a repeat or two. This might even have a third." message.indexOf "This", 0 # => 0 # Modifying the start parameter message.indexOf "This", 5 # => 23 message.lastIndexOf "This" # => 49
Still need recipe to count occurrences of a given string within a message.