.
First, you should count those trains that started at or after 8:30 am in the opposite direction.
There are 6 of them that started at 8:30 am, 8:34 am, 8:38 am, 8:42 am, 8:46 am and 8:50 am.
In addition to it, you should count those trains that started before 8:30 in the opposite direction and arrived
to the starting/ending station after 8:30 am.
Ewan will meet those trains too. (Accounting for these trains and not missing them is the major point of the solution to this problem !)
These are the trains that
started at 8:06 am arrived at 8:30 am (should not be counted)
8:10 am 8:34 am (counts)
8:14 am 8:38 am (counts)
8:18 am 8:42 am (counts)
8:22 am 8:46 am (counts)
8:24 am 8:50 am (counts)
The number of such trains is 5.
So, the total is 6 + 5 = 11, and I do not count the trains at the start or end station, as the condition requires.
This problem was just solved once at the link
https://www.algebra.com/algebra/homework/word/travel/Travel_Word_Problems.faq.question.1108213.html
https://www.algebra.com/algebra/homework/word/travel/Travel_Word_Problems.faq.question.1108213.html
See also the lesson
- More complicated but still elementary logic problems, Problem 2
in this site.
I reproduced this solution here AGAIN for your convenience.