The speech in which Polonius gives his parting advice to Laertes on sending him off to college is so full of excellent practical wisdom that people have wondered why Shakespeare put the words in the mouth of a character who is supposed to be senile and whom Hamlet referred to as one of "these tedious old fools." I believe that Shakespeare wrote such soliloquies, speeches, and asides as separate passages when they occurred to him and then saved them to be used when the right opportunity arose. This might also have been true of Hamlet's "To be or not to be" soliloquy, of Jacques "All the world's a stage" speech, of Macbeth's soliloquy starting with "Tomorrow and tomorrow and tomorrow," and many others. Probably the best thing in Polonius' advice to Laertes comes at the end when he says:
This above all: to thine own self be true,
And it must follow, as the night the day,
Thou cans't not then be false to any man.
The great American philosopher Ralph Waldo Emerson says the same thing in his best essay, "Self-Reliance." Polonius must consider it the most important part of his advice, since he says, "This above all."