A free after-school program provides tutoring in science, math and the “sweet science” in the ring.

Khali Sweeney has a proven formula for educating students: “Books before boxing.”

He created a family environment at the Downtown Boxing Gym in Detroit and an afterschool program flexible enough to address each student’s specific needs.

The results are impressive: Since its founding in 2007, the program has reported a 100 percent high school graduation rate.

“I have the flexibility to focus on a student’s exact problem,” Sweeney said. “A school system has deadlines, a curriculum that must be followed. If I think a kid needs to start, or return to basics in math, that’s what we do.”

Khali Sweeney with students.Courtesy of Downtown Boxing Gym

There are roughly 50,000 students in the Detroit Public Schools Community District, which has a 78.22% high school graduation, according to state data. In recent history the district suffered extensive financial difficulties and mismanagement. From 2009 – 2017 the district was overseen by the state through various appointed emergency managers.

Sweeney’s program, which is free and currently has 250 students, only allows students to step into the boxing ring after they are tutored, mentored and enrolled in enrichment courses like science, math, computer coding and engineering.

Sweeney has learned that children thrive on praise. Teachers give shoutouts throughout the day for all kinds of achievements, including if a student helps another student, improves one grade level or masters a skill.

Staff and students sit together for meals. They exchange jokes, talk about issues at home and look at their Facebook pages.

In class, a teen may sit next to an elementary student because they are both on the same reading level — and no one teases or judges them.

Students work together at the after-school program.Downtown Boxing Gym

Sweeney uses his own story to diffuse any shame or judgment. “I tell kids I wished I was held back and that’s nothing to be ashamed of,” said Sweeney, who taught himself to read after high school.

He nearly closed the gym in 2010, after using up all of his savings. He now has an operating budget of $1.7 million, a mix of foundations, corporations, private donations and some revenue earned from events, merchandise sales and building rental.

Jessica Hauser, executive director of the youth program, arrived about that time, looking for a place to continue her boxing-conditioning routine. She didn’t expect to see children.

Sweeney had two volunteers, lights run by a kerosene generator, no heat and a leaking ceiling. He and the students ate lunch standing up because there were no tables or chairs.

“I was immediately struck by what I saw. It was magical,” said Hauser, who was working on a doctorate in political science at the time.

She dropped out of school, used her savings and sold all of her personal belongings to try to keep the gym open. Eventually, she figured out another way, making the gym a nonprofit organization. Then slowly, the program attracted donors and financial support.

“Khali never took the approach of doing anything less in this community for these kids than the support systems in wealthy communities did for their kids,” Hauser said.

Today, there’s a waiting list of 1,300, something Sweeney and Hauser call “heart-breaking.” There are 35 academic volunteers and usually three to five athletic volunteers. Students, ages 8 to 18, generally attend classes three times a week and stay an average of four years.

Secondary education specialist Amy Mullins works with students at the gym.Downtown Boxing Gym

Shobi Mathew, cardiac arrest coordinator for the city of Detroit, has volunteered for two years. “The camaraderie is indescribable,” he said. “You get to know the kids on a personal level. You can see the difference you’re making.”

Jordan Bell, 19, said he “was struggling in school” when he entered the Downtown Boxing Gym in sixth grade. He graduates in January with a college scholarship he received through the gym. He wants to be a computer science software engineer, something he didn’t know existed until he took computer science at the gym.

“My father got killed when I was 11 and that kind of turned me toward violence and the streets,” he said.

A therapist recommended the gym.

“I was thinking, How the hell will a boxing gym teach me to not fight?” Bell said.

But he quickly fell in love with the way the tutors treated him. “They walk through things step by step. They are patient,” Bell said. “If you mess up, they say everybody makes mistakes.”

What does Bell see as the major difference between school and the gym program?

“That’s easy,” he laughed. “At the gym they treat you like family, no matter your background, race or who you are. As soon as you step through the door, you feel like you are at home.”

This story appears as part of coverage for “NBC News Learn Presents: Education Now Detroit,” a two-hour live community event supported by the Chan Zuckerberg Initiative. For more information, go to nbcnews.com/learndetroit.