Code:
a b b M 2 .
a b 3 M 3 1
a b c 2 d e
We have a mine located at d or e.
Assume a mine at e, then there must no mine in d, a mine at c, none in zone b and 1 in zone a, so
a = 1/3, b = 0, c = 1, d = 0, e = 1.
Checking with
3*a + 4*b + c + d + e =
3*(1/3) + 4*(0) + (1) + (0) + (1) =
3 , so this is consistent.
If instead there is a mine at d, then there is no mine at c or e, one in zone b and one in zone a, so
a = 1/3, b = 1/4, c = 0, d = 1, e = 0.
Checking with 3*a + 4*b + c + d + e =
3*(1/3) + 4*(1/4) + (0) + (1) + (0) =
3 , so this is consistent.
These 2 possibilities are equally likely, so
a = 1/3, b = 1/8, c = 1/2, d = 1/2, e = 1/2.
Checking with 3*a + 4*b + c + d + e =
3*(1/3) + 4*(1/8) + (1/2) + (1/2) + (1/2) =
3 , so this is consistent.
I erred with zone a. It's 1/3 and not 1/6.
As for your solution, it looks like you are lumping c together with zone b when clearly c cannot be treated in the same way as zone b.