Suppose you're given three nxn matrices A, B, and C, and you want to check whether AB=C. You could, of course, multiply AB and compare it with C, using O(n3) time with the obvious multiplication algorithm or O(n2.8) time with the Schönhage-Strassen algorithm, but intuitively it seems it ought to be easier to check the multiplication than to compute it.
Let v be an n-vector of 1's and 0's, each entry chosen independently by flipping a fair coin. Prove that if M is a non-zero nxn matrix, the probability of Mv=0 is at most 1/2. Using this fact, give a randomized algorithm to test whether AB=C in O(n2) time, and explain why your algorithm is never wrong.