mathing string in python
Posted
by nani
on Stack Overflow
See other posts from Stack Overflow
or by nani
Published on 2010-06-16T09:51:04Z
Indexed on
2010/06/16
9:52 UTC
Read the original article
Hit count: 205
python
Write two functions, called countSubStringMatch and countSubStringMatchRecursive that take two arguments, a key string and a target string. These functions iteratively and recursively count the number of instances of the key in the target string. You should complete definitions forthe remaining problems, we are going to explore other substring matching ideas. These problems can be solved with either an iterative function or a recursive one. You are welcome to use either approach, though you may find iterative approaches more intuitive in these cases of matching linear structures
© Stack Overflow or respective owner