WASHINGTON -- President Obama said the United States has not overcome its history of racism -- and he is using the "N-word" to make his case.

In an interview, Mr. Obama weighed in on the debate over race and guns that has erupted after the arrest of a white man for the racially motivated shooting deaths of nine black church members in Charleston, South Carolina.

"Racism, we are not cured of it," Mr. Obama said. "And it's not just a matter of it not being polite to say nigger in public. That's not the measure of whether racism still exists or not. It's not just a matter of overt discrimination. Societies don't, overnight, completely erase everything that happened 200 to 300 years prior."

Mr. Obama's remarks came during an interview out Monday with comedian Marc Maron for his popular podcast, where crude language is often part of the discussion.

Get Breaking News Delivered to Your Inbox

The president said while attitudes about race have improved significantly since he was born to a white mother and black father, the legacy of slavery "casts a long shadow and that's still part of our DNA that's passed on."

White House Spokesman Josh Earnest reiterated that the president was talking about the whole history of race relations in this country and pointed out that the president used the N-word repeatedly in his first book "Dreams from my Father." One incident Obama related in his memoir is one from his mother's childhood - his grandmother told him that she had once come upon a group of children taunting and yelling the epithet at his mother and her black friend as the two shared a book.

Mr. Obama also expressed frustration that "the grip of the NRA on Congress is extremely strong" and prevented gun control from advancing in Congress after 20 children and six educators were massacred in a Connecticut elementary school in 2012.

"I will tell you, right after Sandy Hook, Newtown, when 20 6-year-olds are gunned down, and Congress literally does nothing - yes, that's the closest I came to feeling disgusted," he said. "I was pretty disgusted."

He said it is important to respect that hunting and sportsmanship are important to a lot of gun-owning Americans. "The question is just is there a way of accommodating that legitimate set of traditions with some common-sense stuff that prevents a 21-year-old who is angry about something or confused about something, or is racist, or is deranged, from going into a gun store and suddenly is packing, and can do enormous harm," Mr. Obama said in a reference to suspect Dylann Storm Roof, whose purported 2,500-word hate-filled manifesto talked about white supremacy. Roof faces nine counts of murder in connection with Wednesday's shooting.

Mr. Obama sat for the interview Friday in Maron's Los Angeles garage studio - close to where the president attended Occidental College - and seemed to marvel at the absurdity of it. "If I thought to myself that when I was in college that I'd be in a garage a couple miles away from where I was living, doing an interview as president, with a comedian ... it's not possible to imagine," he said. But he said he did the interview because he wants to reach a nontraditional audience and "break out of these old patterns that our politics has fallen into" where "it's not this battle in a steel cage between one side and another."

With the campaign to replace him heating up, Mr. Obama said he thinks he would be a better candidate if he were running again, because although he's slowed down a little bit, "I know what I'm doing and I'm fearless."

"I've screwed up. I've been in the barrel tumbling down Niagara Falls. And I emerged and I lived. And that's always such a liberating feeling," he said.

CBS News White House Correspondent Bill Plante contributed to this report.