Obama uses N-word, says slavery still 'casts a long shadow'

President Barack Obama says the United States has not overcome its history of racism and is using the N-word to make his case.

In an interview, 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.

Read MoreThese states depend on 'Obama phone' the most

"Racism, we are not cured of it," 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."

President Barack Obama
Getty Images
President Barack Obama

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.

More from NBC News:
Cops hunting killers swarm NY towns
17,000 acres burnt as California wildfire rages on
Body of former White House chef found after hike

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."

Obama also expressed frustration that "the grip of the NRA (National Rifle Association) 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."

New development in Charleston shooting
New development in Charleston shooting   

He said it's 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," 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.

Read MoreNew development in Charleston shooting

With the campaign to replace him heating up, 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.