Probably a better solution, still not the best.