Let (f,g) be a pair of functions satisfying the given condition. We shall show that f′′ is constant. Suppose that f′′ is not constant. Then, because (f(x)−g(0))⋅(f′(x)−g′(0))⋅(f′′(x)−g′′(0))=0, for all x∈R, and f′′ is continuous, there is a∈R and r>0 such that f′′(x)∈/{0,g′′(0)}, for any x∈(a−r,a+r). It follows that (f(x)−g(0))⋅(f′(x)−g′(0))=0, for x∈(a−r,a+r).
Two cases are possible.
Case 1. There exists b∈(a−r,a+r) such that f′(b)=g′(0). By continuity of f′, there is s>0 such that (b−s,b+s)⊂(a−r,a+r) and f′(x)=g′(0), for all x∈(b−s,b+s), implying f(x)=g(0) for x∈(b−s,b+s). We get f′′(x)=0 for x∈(b−s,b+s), a contradiction.
Case 2. f′(x)=g′(0), for any x∈(a−r,a+r). We obtain f′′(x)=0, for all x∈(a−r,a+r), a contradiction again.
Thus f′′ is constant on R.
Let m∈R such that f′′(x)=2m, for any x∈R. As (f′(x)−2mx)′=0, for all x∈R, there is n∈R such that f′(x)−2mx−n=0, for x∈R. As a consequence there exists p∈R such that f(x)=mx2+nx+p, for all x∈R.
In the same way, g′′ is constant on R, implying the existence of m′,n′,p′∈R such that g(x)=m′x2+n′x+p′, for x∈R. In the case m=m′, as the equation (f(x)−g(x))⋅(f′(x)−g′(x))=0 has at most three real solution, the condition of the problem is not possible. Thus m=m′, so the pairs of functions satisfying the given conditions are of the form f(x)=mx2+nx+p and g(x)=mx2+n′x+p′, for any x∈R.