According to CNN, the comedian attended a ceremony on Thursday in Washington to speak about his early life in the service.
"I wasn't a bad boy, I was just sort of left to wander around," said Cosby, who served as a hospital corpsman as a young man.
The Cosby Show star joined the Navy in 1956.
"I don't want to join the Army because I'll die in a foxhole in dirt... I don't want to be in the Marine Corp because you die before you get out of there," he told the crowd at the ceremony.
He continued: "I want to be in the Navy, because no matter how you die, you're in the middle of the ocean and it will wash out your underpants and that will make my mother very happy."