solve n