Write down the solution for this math problem: Solve -583*q + 660*q + 512 + 412 = 0 for q.
-12