Robin Williams with Conan O'Brien
THE TONIGHT SHOW WITH CONAN O'BRIEN -- Episode 145. Pictured: Robin Williams during an interview with host Conan O'Brien on Jan. 21, 2010. Photo by Paul Drinkwater/NBC/NBCU Photo Bank via Getty Images

Robin Williams was a favorite funnyman for decades after a series of iconic roles in movies including "The Birdcage," "Mrs. Doubtfire" and "Hook." But the Juilliard-trained actor also won over fans with more serious roles that explored the meaning of life and death.

In "Good Will Hunting," Williams played the wise psychologist that helped Will Hunting find meaning in his life. In "Dead Poets Society," he was the English teacher who made poetry seem as essential as oxygen. In "What Dreams May Come," Williams portrayed the heartbreaking role of a man searching for his wife in the afterlife.

"'O Captain, my Captain.' Who knows where that comes from? Anybody? Not a clue? It's from a poem by Walt Whitman about Mr. Abraham Lincoln. Now in this class you can either call me Mr. Keating, or if you're slightly more daring, 'O Captain my Captain,'" said Williams, portraying John Keating in "Dead Poets Society."

Here's a roundup of some Williams' meatier roles.

From "Dead Poet's Society:"

From "What Dreams May Come:"

From "Good Will Hunting:"

From "The World According to Garp:"