New solution, works better