Problem: I have a string '01234(01)3423(32)' and I want to count the pattern of this string. I consider as pattern '0','1','2','3','4','(01)','3','4','2','3','(32)' –> pattern=11. If I use 'size' or 'length', this function count as pattern '(' '0' '1' ')' that i consider all togheter as one pattern '(01)'. Can you give me some suggestions to solve the problem?
MATLAB: Count pattern of a string
countpatternstrings
Related Question
- How to compare numeric strings
- Count occurrences of sub-string in a long string (How many times a sub-string appear)
- Regular expressions with regexp.
- I want to split cell vector
- Working with Dates,Problem with syntax
- If a string contains any of the strings from an array
- Regular expression for matching substring with wildcard
Best Answer