Naomi Weintraub took her two-hour precalculus final exam at Montgomery Blair High School with great expectations. The 10th-grader had studied, completed her review packet and earned A’s in both quarters. But her grade on the January exam: D.

“I was so upset,” said Naomi, 15. “I worked so hard.”

Sergio Bolanos, 14, a ninth-grader at Northwood High School, decided to hit the books for his January geometry exam but strategically opted not to go all-out. He was aiming for a C. “I had an A first quarter and an A second quarter, so on the final exam, it didn’t really matter what I got,” Sergio said. The result: He failed.

Both students are part of what has become a startling phenomenon in Montgomery County’s high schools: High rates of failing and near-failing grades on math final exams.

In a suburban county far more accustomed to the glow of success and national accolades for school performance, parents and elected leaders are demanding answers: Why did 62 percent of high school students flunk their geometry finals in January? Why did 57 percent bomb their Algebra 2 exams? Why did 48 percent falter on the final test in precalculus?

Those questions intensified late Friday, when school officials released detailed data showing the high failure rates were consistent across five school years and that some Montgomery high schools had particularly poor results. The math exams are countywide and uniform across all schools.

“I’m just amazed this hasn’t blown up a long time ago,” said Mel Riddile of the National Association of Secondary School Principals, where Montgomery’s latest exam results have left many wondering whether similar problems are hiding in other districts.

School leaders, experts and teachers offer several possible explanations for the poor exam performance, which dates back more than a decade in algebra, according to school system reports and board minutes.

They say it could be that the longtime push in Montgomery to accelerate students in math has moved too many students too quickly and left them with an understanding of the subject that isn’t deep enough.

It could be that the day-to-day classroom instruction is not preparing students for what awaits at semester’s end.

Or it could be — for some, like Sergio — a choice: Many students make their own calculations about whether revving up for the big test makes sense, given the grades that precede it can render the test moot.

Montgomery students said they often refer to a chart, posted on an archived county PTA Web site, that details 125 grade scenarios, only four of which would lead to failing a course because of failing the final exam. Schools officials confirmed the chart’s accuracy.

For example, with C’s in each of a semester’s two quarters, an E on the final exam would still result in a C for the course. A student with two B’s going into the final exam needs only a D or better on the test to maintain a B for the course, according to the chart. The exam, worth 25 percent of a course grade, holds sway but can be greatly outmatched by daily classroom performance over time.

“Maybe the teenagers are blowing it off because the district is blowing it off,” said Tom Loveless, a senior fellow at the Brookings Institution who studies student achievement. “If the district doesn’t take the exams seriously, I don’t understand why they give them.”

Danielle Bartley, a student at John F. Kennedy High School, failed an exam two years ago, and it served as a wake-up call. Now 17 and a junior, she has rebounded, and her mother, Danna Walters, says perhaps finals should carry more weight. “It pushes them harder to think,” Walters said.

Superintendent Joshua P. Starr called the exam failure rates “unacceptably high” for some courses, but described the tests as only one measure of student success. Montgomery students on average outperform the state and nation in math on the SAT, and Starr pointed out that student scores have been rising over the past five years. The average student score in Montgomery on Advanced Placement math exams also has increased.

All of this has made the final exam problem even more puzzling to some. Experts point out that AP and SAT results often track with wealth. But 90 percent of Montgomery students also pass Maryland’s state high school algebra test.

Starr has created work groups to examine issues related to the county math exam failures, including policy, curriculum alignment, professional development and instructional effectiveness. He said he would like at least some changes in place by fall.

Montgomery has been more focused on course completion than on final exam grades, Starr said. The data school officials released Friday night show recent course failure rates of 12 percent for Algebra 2 and 16 percent for geometry, far below the final exam failure rates in those courses.

Signs of math trouble also show up among Montgomery students who attend Montgomery College after graduation, with nearly 70 percent needing remedial classes before they can take college-level math, according to 2012 college figures.

Jerome Dancis, an associate professor emeritus in math at the University of Maryland who has followed math issues in Montgomery for more than a decade, said he is not surprised by the failing grades because students have long needed more of the basics — multiplication, division, percentages, decimals, exponents — and fewer calculators.

“If they are not fluent in arithmetic, then they are going to have trouble in Algebra 1, Algebra 2 and Precalculus,” Dancis said.

Montgomery teachers trace the math failures to a combination of issues.

Russ Rushton, head of the math department at Walt Whitman High School, said students are savvy test-takers who target their studying efforts. “If I know it’s not going to be worth a lick, I’m not going to care too much about studying for it,” Rushton said.

He and other teachers said student absences are a factor because it does not take many missed days to leave a student seriously behind in math. One math teacher who spoke on the condition of anonymity because of the sensitivity of the issue said that nearly 25 percent of his students have racked up 10 or more classroom absences and that attendance for final exams is “appalling.”

Another math teacher, also speaking on the condition of anonymity, said that many struggling students are trying to pass courses, not exams. It’s not all about the learning, he said, “it’s all about getting kids through.”

Teachers interviewed in recent days also disputed the idea that the tests do not match what they are teaching in class, as some parents have claimed.

Several teachers said Montgomery’s acceleration of students — placing them in higher-level classes before they master the basics — is a key element of the failure rates. Montgomery has taken steps recently to pull back on math acceleration.

“It’s depressing, but I’m optimistic we’re on the way to fixing it,” said Montgomery Blair math teacher David Stein. “We’re looking in a more thoughtful way at who we move up in math.”

Margaret Smith, whose daughter is a junior at Springbrook High School, said that some students reach a point when the gaps in their math learning are too significant. “Some of them have suffered from having shaky foundations,” Smith said. “They’ve managed to get through, and it catches up to them.”

Although the recent failure rates have alarmed parents and members of the school board, the problem goes back a long way. In 2000, the Board of Education discussed Algebra 1 exam failure rates of 64 percent. In 2004, a report showed that about half of high school students were flunking Algebra 1 final exams. In 2006, a report found that 54 percent had failing Algebra 1 final exams in high school.

In those years, high-achieving middle school students increasingly took Algebra 1, and they tended to do better on the exams. When data is combined for middle and high school students, the picture improves for two courses: Algebra 1 and Honors Geometry.

The 2013 data show that about 16,000 high school students did not pass their final exams across seven math courses — a majority of the roughly 30,000 who took the tests.

“I really believed we had taken steps to fix this problem,” said school board member Patricia O’Neill, recalling the discussion about low marks on Algebra 1 high school exams in 2000. Every principal in Montgomery should be examining the data classroom by classroom, she said.

As her second semester precalculus exam approaches, Naomi Weintraub, the sophomore at Blair, is bracing for another disappointment. In January, she recalls feeling “awesome” as she left the exam and doing a double-take as she read the report card weeks later. “I don’t know how this happened,” she remembers thinking.

A few months later, she heard about the widespread exam failure: In precalculus, 62 percent of students received D’s or E’s on January finals.

“I’m not the only one,” Naomi said. “I was losing faith in the idea that if I work really hard I will get the grades I deserve.”