Find String that all set of strings are substring of

*
Last edited on
Can you rephrase the problem? I don't understand what is being looked for, nor what '*' means. What I understand is:
1. '*' is the wildcard character. I.e. it stands for an arbitrary substring of any length, including zero.
2. The input strings are wildcard patterns, and the output must be any string that matches all inputs.
If this is correct, I don't see why the second example has no solutions. Both "AQ" and "QA" should be solutions: "**Q**" is the same as "*Q*", which means "the string must contain Q", while "*A*" means "the string must contain A", so any string that contains both Q and A would meet both conditions.
On the other hand, I don't see why "abundance" is a solution of the first example, "*B*D" should mean "the string contains B and D, with D coming after B and being the last character in the string". I think "ACEBD" could be a solution.
Another shit-canned post from aceadams.
https://www.cplusplus.com/forum/general/269160/

Is it worth bothering replying to this shrub anymore?
Topic archived. No new replies allowed.