You must get the magic words in your head.
Directly Proportional ==> kx
Inversely Proportional ==> k/x
That's about it.
"M is jointly proportional to a, b, and c and inversely proportional to d."
M = k(abc)/d
Really, that's all there is to translating these. The rest is a substitution exercise.
"a = d"
M = k(abc)/a = k(bc)(a/a) = kbc
"b and c are both 2"
M = kbc = k(2)(2) = 4k
"M = 128"
M = 4k = 128
You should be able to solve that for 'k'.