The key to solving this type of problem is to realise that the acceleration
of B is half the sum of the accelerations of A and C. Note also that
there is only one string passing over free moving pulleys so the tension
in the string is the same at all points.