add solution to example 1