starting a solution for infinite loops