Hello
Assuming I have a sentence like so:
“Hello %1, I %3 %4 five days day ago. %5 need to talk to %6 later”
The sentence has wild cards that can be used as placeholders for actual strings which will replace the tokens.
Such replacement can yield the sentence
“Hello [b]Jeff[b]saw[b]you[b]I[b]you
The sentence above has 6 such placeholders.
Here is my question:
Given such sentence, how can I tell how many wild cards it has?
Note that the number isn’t limited to 1-9 but theoretically be very high.
I tried to use split with regular expressions but I must be using the wrong regular expression (I am fairly new to them).
I would appreciate any help