Solve problems 35-36 using C++.