How to solve this situation