#21 - Word Search

Example 1

Input

S = "hello world"

T = "world"

Output

Found at index 6

Example 2

Input

S = "programming"

T = "gram"

Output

Found at index 3

Example 3

Input

S = "helloworld"

T = "hi"

Output

Not Found

Last updated