solve the spell problem