Input (grade 2): While she was in Peru, she learned to speak Spanish.
Output (grade 6): The time she was in the country Peru, she learned to speak the language Spanish.