The question seems rather simple, yet it is suprisingly difficult.
There is a bug under one of six tiles and it is my job to find it. The tiles lie in a row. At night, the bug moves randomly 1 tile, so it either moves to the left or to the right. During the day you are allowed to pick up one tile to see if the bug is there. If you choose the tiles as optimal as possible, how many days will it take you to find the bug, at most?
The answer is multiple choice, namely a.) 6 days, b.) 8 days or c.) 10 days.
Lets defne the tiles as follows: the first tile on the left we call 1, then the tile on the right of the first tile we call 2, etc. until we have a set {1,2,3,4,5,6}.
MY APPROACH: [I was thinking that you start with 3. You find that it's not there, but the bug could have been under 4 and moved during the night under 3, so the next day you lift 3 again. It's not there, but the bug could have gone from 5 to 4 and now there is again a possibility that the bug moves under 3 when you decide to lift another tile, so again you would think it's best to lift 3. Since the bug can move between 5 and 6 back and forth it is useless to continue looking under just tile 3. But if you decide to look under another tile there is always the possibility that the bug will move under the tile you looked under one days before that. Therefore, it seems to me that the problem is unsolvable.
I tried to visualize the problem on a lattice of 10 by 6 where every day (the number of rows) is representated by a row of 6 tiles. Then drawing two lines from every tile in the first row to the left and right tile in the row below and leaving out the lines from the tile I looked under. Then I eliminated the tiles to which the most lines come to. But after 10 days there are about 4/5 lines per tile, so this doesn't work even though it seems rock solid to me.]
Does anybody have any suggestions or solutions?


I think Peter's solution elsewhere in the thread works, and I think the following solution also works, but is shorter.
$$2,3,4,5,5,4,3,2$$
Proof:
So the answer is that no more than 8 steps are needed.
Addendum 2019-08-28: I find it very surprising that, no matter how many tiles there are, we can always guarantee to find the bug! The strategy of this post is easily extended to find the bug in at most $2n-4$ guesses, where $n$ is the number of tiles.
Addendum 2019-10-09: The paper Finding a princess in a palace: A pursuit-evasion problem (Britnell, John R. and Mark Wildon, 2012) generalizes this problem to a bug moving from node to node of an arbitrary graph, rather than just a line, and proves the following remarkable results: