Just so you don't think that these problems always have easier solutions, consider the following example.