What makes a great teacher great? That's the question at the heart of 50 Great Teachers, from the NPR Ed Team.

Sarah Hagan has a passion for math, and the pi-shaped pendant to prove it.

The 25-year-old teaches at Drumright High School in Drumright, Okla. The faded oil town is easy to miss. Fewer than 3,000 people live there, and the highway humps right around it.

There are no stoplights, no movie theater and no bowling alley anymore. Just a clutch of small houses and hearty businesses: a funeral home, Family Dollar and a Dollar General.

That makes it hard enough to attract good teachers, says Judd Matthes, Hagan's principal. But it gets worse.

"We don't pay a lot in Oklahoma for beginning teachers," he says, laughing from behind his desk in the school's basement. "If you go next door to Arkansas, they're about a $10,000-a-year starting salary difference."

Which made Matthes wonder why a National Merit Scholar who had gotten a full ride to the top-notch University of Tulsa would want to start her teaching life in a place like Drumright, earning just over $30,000 a year.

Sarah Hagan's answer:

"It was April, and I hadn't graduated yet. And they said, 'Come work here.' "

Hagan, now in her third year at Drumright High, grew up outside of Tulsa. Home wasn't urban, but it wasn't Drumright, either. She hadn't planned on working in such a poor, rural district and got quite a shock when she arrived.

"The first time I saw my classroom," Hagan says, "it was the most depressing thing I'd ever seen. The walls weren't all painted one color. There was no dry-erase board. There were no bulletin boards."

And the floorboards squealed. They still do, but the rest of her room is now an unrecognizable riot of color.

Decorations hang wall-to-wall, floor-to-ceiling. A poster of Albert Einstein. Paper pompoms. A podium decorated with a sign in pink, purple and yellow reads: "Ms. Hagan, Teacher of Awesome (and by "Awesome" I mean "Math")." After each school year, she tears it all down and starts over.

This is the first key to understanding Sarah Hagan: She's a visual person.

Hagan is also remarkably self-assured. When she arrived at Drumright, her classroom wasn't the only challenge. The school had ordered new math textbooks, but Hagan had already decided — as a student-teacher — that she wasn't going to use textbooks.

"I don't want to be stifled by that. I mean, I teach a lot of things in a totally different order than a textbook would," she says.

To Hagan, the average math textbook was, itself, a problem to be solved.

"I decided we were gonna make our own textbooks."

She simply left the new books in their boxes. Instead, in a standard lesson, she uses everything in the classroom but a textbook: a flower pot, a garbage can, a roll of tape, loose spaghetti.

Yes, spaghetti. It's all part of Hagan's DIY approach to teaching and learning.

As for the textbooks they make, her students begin with blank composition notebooks. Each day, Hagan hands out a lesson she has written herself or open-sourced from other teachers across the country. It's usually printed on colored paper and requires some kind of hands-on work: drawing, coloring, cutting.

There's even some basic origami.

Students then glue the results into their notebooks. Eventually, the books look like dog-eared, bulging relics from an Indiana Jones movie. Hagan argues that if students are allowed to be creative, they're more likely to remember what they've learned.

"The point is, we shouldn't have to be like, 'Oh, yeah, there's that chart on Page 763 that tells me how to classify something.' They should think, 'Oh, that's on that blue paper that we did a few days ago, and I doodled in the corner,' " she explains.

One morning, in Hagan's Algebra I class, the handout is orange, and the lesson is on naming polynomials — drudge work even for math enthusiasts.

So Hagan shakes things up. After walking the class through the differences between cubic and quintic, binomial and trinomial, she asks:

"So, you guys ever gone speed-dating?"

Math speed-dating.

Hagan hands the students slips of paper with a polynomial written on one side and its name on the other. She demonstrates with a confused football player. He holds up his card, and she names his polynomial. He then tries to do the same.

And it's important, Hagan tells them, not to let wrong answers linger:

"Because I don't want him thinking I'm someone I'm not."

And with that, the dating begins. At first, some of the students — especially the boys — seem a little reluctant. It's as if they don't want to be seen having fun in math class. But that lasts just a few minutes. Soon, everyone is bounding in and out of pairs, laughing and struggling and encouraging each other.

That afternoon, in Algebra II, Hagan comes up with a creative way to get her students to memorize the quadratic formula. She sings it to the tune of "Pop Goes the Weasel."

Their assignment: Sing the formula — from memory — to a teacher, a family member and a third person of their choosing. And witnesses have to sign a form proving it happened.

"She really tricks us into learning," says sophomore Jake Williams. "There's so much fun involved in the classroom and the learning part that we actually understand it and grasp it."

"You do puzzles and all kinds of stuff," says senior Krissy Hitch. "So it doesn't even really seem like you're learning. But then, when you take the test, you realize: 'Wait, when did I even learn all this stuff? Where did that even come from?' "

Junior Taylor Russell came to Hagan's class a skeptic:

"I have never, ever liked math. But this year, I really love math."

Making it fun matters. Algebra is high-stakes. A student who can't pass the state test can't graduate. Hagan even changed her grading system to make sure students know the math.

"You either get an A, a B, or a Not Yet," explains junior Ainsley Flewellen. "It's impossible to fail. She makes it where you can't not pass her class."

Hagan's no pushover. If a student bombs a quiz or an assignment, he has to do it again. And again. Until he gets an A or a B. But he's not struggling alone. Hagan is always there to help.

"She'll stay after school really, really late with you and help you with it. I've had to do that multiple times," Russell says.

That explains why, at lunch, students come to Hagan's empty classroom just to hang out or ask her for help with an assignment — even if it's for another teacher's class.

"She wants her students to be successful," says fellow teacher Melinda Parker, who can't say enough about Hagan. "Oh, we love Sarah. She works so hard. And we got her in Drumright. We got her in Drumright, Oklahoma!"

Parker does worry that the young math teacher could burn out. Hagan admits — sometimes — the work wears her down.

"Yeah, there's days where I complain. And the people I complain to think I'm insane because I haven't left this place. But these kids deserve better."

And so she stays, at least for now. Even in her scant free time, Sarah Hagan doesn't really leave the classroom. She writes a blog about teaching.

Copyright 2016 NPR. To see more, visit http://www.npr.org/.