The Three Languages
It is Aarne-Thompson type 671.
A count's son could learn nothing. The count sent him to find a master who could teach him something. One year later, he came back saying he knew what dogs said when they barked; the next, what birds said; the third, what frogs said. Infuriated by his uselessness, his father drove him out.
He was offered a night's shelter in a tower, but warned that wild dogs barked and howled there, and every night ate a man. He went and came back, saying that the dogs were there to guard a treasure until it was taken, and they had told him how to take it. The lord of the castle asked him to do it, and he came out with a chest of gold, and the lord adopted him as a son.
He went to Rome. On the way, listening to frogs made him thoughtful. In Rome, the Pope had died, and they could not choose his successor, and were looking for some marvelous sign. Two doves descended on him, and they chose him as Pope — as the frogs had foretold. The doves persuaded him, and he had to sing Mass, but the doves whispered how to do it in his ear.
The story is a classic example of the archetypal hero's progress through life. In Lemony Snicket: The Unauthorized Autobiography, there is a rendition of the tale. For the Count's son; learning and education has meaning to the beholder, and in some cases, only to the beholder. In addition, there is an expectation that knowledge is power[full] and can allow the beholder of knowledge to become self-sufficient/self-reliant.