solved problem 346