On the wall of Kimberly Rosario’s classroom at San Francisco’s Mission High hangs a list of answers, from A to Z, that finish the sentence, “Doing math is ...”

Analyzing. Building. Calculating ... Zeroing in on solutions.

The same can be said for how Rosario, a geometry teacher, pieces together ways to make her stressful life work. She and her husband, who does administrative work at Kaiser, can’t afford to buy a home anywhere near her workplace in one of the most expensive cities in the world — so she commutes from Sacramento.

She has her routine down to a carefully considered math problem. Shower and lay out clothes at night. Set alarm for 3:30 a.m. Jump in the car by 4 a.m. to beat the Bay Bridge back-up.

Pull into the parking lot at Mission High at 5:30 a.m. Ensure the lot’s gate is locked behind her. Ensure her car is locked. Set a second alarm for 7:15 a.m. Go back to sleep in the passenger seat. Get to Room 330 by 7:30 a.m. to help kids needing extra assistance. Start official school day at 8:10 a.m. — four hours and 45 minutes after her first wake-up.

“It’s not logical. My students tell me all the time, ‘You’re crazy for commuting so far!’ They speak a bit of truth,” said Rosario, 35. “I shouldn’t have to commute 100 miles one way to my job. I should be able to live in the community where my students live.”

Yes, she should. And Prop. E on the Nov. 5 ballot would help the city inch slowly toward that reality. It would make teacher housing and 100% affordable housing faster and easier to build and would allow those projects to be built on land currently zoned for public use except for parks.

In the meantime, San Francisco’s treatment of public school teachers is pretty pathetic. Yes, teacher pay has climbed a bit over the years, but housing prices still remain far out of reach for teachers.

Many school teachers pack together in apartments like college students, rent dining rooms or living rooms in other people’s houses, squeeze their families into little studios, work second and third jobs or commute insanely long distances. I talked to one who is looking to buy an RV to call home.

Max Raynard, a third gade teacher at Rosa Parks Elementary’s Japanese Bilingual Bicultural Program, speaks fluent Japanese and holds a teaching credential and master’s degree. He’d love to stay in his native San Francisco, but can’t afford more than the $2,400 monthly rent he and his wife pay for their small one-bedroom apartment. They’d like to have children, but want a bigger place first so he’s debating whether to give up his dream job or his dream city.

“It feels like I’m being punished because I went into public service instead of inventing a dating app for dogs or something,” he said.

Susan Solomon, president of the United Educators of San Francisco, said many teachers report spending up to 60% of their income on housing — twice as much as what the federal government recommends. That, plus student loan debt, means, “There’s just so much pressure on them,” she said.

To be sure, Prop. E doesn’t do enough. Mayor London Breed pushed a different version of the measure and, separately, proposed a charter amendment to allow all 100% affordable and teacher housing projects to be approved automatically if all zoning requirements and other city rules were met. Frustratingly, neither made it past the Board of Supervisors.

Nonetheless, SPUR, an urban think tank that works to find nonpartisan solutions to city problems, recommends voters pass Prop. E as a “small step forward” that will have “at least some tangible benefits.”

In truth, what we need are major steps forward with big, immediate benefits. The San Francisco Unified School District needs to find more ways to trim fat and pay teachers more. And City Hall needs to find more ways to help such as dedicating leftover property tax money intended for the public schools to the school district for teacher raises.

(Instead, Breed has tagged most of it for homeless services despite, curiously, not wanting to hit up the city’s richest businesses for the same purpose in last year’s Prop. C.)

In the meantime, the city’s first teacher housing project is slowly becoming reality. The late Mayor Ed Lee chose the site in the Outer Sunset and committed $44 million to the project in May, 2017 after this column featured the story of a homeless math teacher. The idea had been discussed — with no real progress made — for 20 years.

At the time of the announcement, the mayor’s administration said teachers could move in by 2022. That has already been pushed back to the last quarter of 2023 — four years away and 6½ years after the project was announced. The pace at which City Hall moves is truly astonishing — and not in a good way.

According to the Mayor’s Office of Housing, the school district is exploring the feasibility of building teacher housing on three other sites: at 7th Avenue and Lawton Street, former site of Clancy’s pumpkin patch; 200 Middle Point Road in the Bayview; and 20 Cook St. in Laurel Heights.

Passage of Prop. E would help construction on the Outer Sunset site start more quickly and could help nudge the other projects along, too.

But they’ll all come far too late to keep Rosario, the Mission High geometry teacher, in the district. She and her husband bought the Sacramento house when she taught in that area, but she always dreamed of moving back to the Bay Area where she grew up. She took a teaching job in San Francisco in 2015 thinking she’d figure out a way to move closer, but the high housing costs coupled with her inadequate salary of about $70,000 annually has made for a math problem she just can’t solve.

“I guess I was naively optimistic,” she said.

She loves Mission High, her colleagues and her students. Her wardrobe of goofy math T-shirts includes one that shows a triangle telling a circle, “You’re pointless.” On Monday, her shirt read, “Come to the math side. We have pi.”

After her long days in the classroom, she still has a 2½-hour drive home on a good day. On Fridays, it’s more like four hours. She has a 13-year-old son who loses out on time with her the longer she’s stuck in a car. And she’s so wiped out when she gets home, she struggles to find the energy and enthusiasm he needs.

And so this will almost certainly be her last year at Mission High. And it might be her last year teaching math altogether.

“It’s a struggle I feel like I’m constantly thinking about,” she said. “And I have a lot of time to think about it because I spend so much time in traffic.”

San Francisco Chronicle columnist Heather Knight appears Sundays and Tuesdays. Email: hknight@sfchronicle.com Twitter: @hknightsf Instagram: @heatherknightsf