### TestTrial's blog

By TestTrial, history, 12 days ago,

I've spent quite some time figuring out why is it that for problem (8A - Train and Peter), instead of "forward" at test 14, my output is "both", but to no avail. Since the entire string is hidden and I am shown just a part of it, it's quite hard to understand where the mistake could be. Here is my submission: 95835050. Thank you in advance. Edit: Some flaws fixed but no real result yet 95837954

• +10

 » 12 days ago, # |   0 Consider input: abcdefgh abc ab you print both even though the answer is fantasy.
•  » » 12 days ago, # ^ |   0 Thanks for the hint, i added the condition (strstr(v,a1)!=rstrstr(v,a1) || strstr(v,a2)!=rstrstr(v,a2)), still no progress on test 14 though
•  » » » 12 days ago, # ^ |   0 Can you write down the condition for a pattern to be possible forward? (ignore backward for now)