test problem solution second attempt