She is the daughter of Spanish immigrants who spent over 40 years in the New York City school system before being appointed chancellor.

He is the son of Cuban immigrants who spent 25 years in the Newark school system before being chosen as superintendent.

She took the reins after a controversial predecessor closed schools, fueled the growth of the charter sector, and made it easier for principals to remove teachers.

He is about to do the same.

She is Carmen Fariña, who in March stepped down as chief of New York City schools, and he is Roger León, who in July will take over as Newark’s new superintendent. As León gears up for the job, Fariña’s tenure across the Hudson may offer some lessons about steps to take and snares to avoid.

Of course, there are big differences between their neighboring districts. New York City’s serves vastly more students – 1.1 million, compared to 36,000 in Newark – and is controlled by the mayor, while Newark schools are once again overseen by a school board.

Yet Fariña’s efforts to stabilize a system that was still reeling from the seismic policy shifts of her predecessors could provide clues about how León might manage a similar transition in Newark. And Farina’s missteps, and the resistance she encountered, could serve as a cautionary tale for Newark’s new schools chief.

“Only when we are able to be contemplative and meaningful,” León said at a recent forum, “are we able to avoid repetition of history.”

Here are three lessons that León can take from Fariña’s tenure:

Set your own agenda — “not reform” is not enough.

Fariña, like León, took over after a period of contentious changes billed as urgent reforms. As she quickly found, that made it easy for critics to attack her as anti-reform.

The system she inherited had been fundamentally reshaped by Joel Klein – a former prosecutor who during his eight years as schools chief became a hero of the so-called education reform movement, which sought to overhaul urban districts through a focus on achievement data and accountability. Graduation rates rose under Klein and funding from wealthy donors poured in. But many teachers felt unfairly blamed when students did not do well on tests, and many parents railed against school closures and the placement of charter schools in the same buildings as district schools.

Fariña, who was handpicked by New York City Mayor Bill de Blasio in 2014, took an entirely different approach. She got rid of Klein’s school letter grades, signed off on teacher raises, and talked about turning schools into “stress-free zones.”

She called this strategy of reversing past policies while enacting new ones “undo while you’re doing,” and people’s views on it depended on how they felt about her predecessor. Klein critics celebrated her style as empowering to educators, while his supporters panned it as backward-looking and complacent.

One of those supporters was Christopher Cerf, a former Klein deputy who became New Jersey’s state education commissioner and later Newark’s superintendent before stepping down in February. When he was asked earlier this year whether he was concerned that some of his policies could be reversed as Klein’s had been in New York, he slammed that approach.

“When your reform strategy is organized around reversal and retrenchment and revenge, that’s not a strategy,” he said, without naming Fariña.

In fact, Fariña did more than unwind Klein-era policies. She laid out a theory of school improvement that emphasized cooperation among educators, and designed a school-to-school mentoring program to bring her vision to life. Still, the anti-reform critique was hard to shake.

Roger León will soon take the wheels of a system that underwent many of the same upheavals as New York when Cerf and his predecessor, Cami Anderson, brought parts of Klein’s reform playbook to Newark when it was still under state control.

León will likely face pressure – including from some of his bosses on the school board – to reverse certain policies that Cerf and Anderson enacted, including one that folded charter and district school admissions into a single system. But he will also be expected to define his own vision and agenda, and to craft a plan for carrying it out.

“There’s a lot of folks in Newark who will welcome a respite from big-R Reform,” said Jeffrey Henig, a political science and education professor at Teachers College, Columbia University. “But at some point, [León’s administration] is going to have to show that they stand for something other than ‘not reform.’”

Pick your fights carefully — especially with well-funded adversaries.

New York City, like Newark, has its fair share of charter school skeptics. But, as Fariña learned when she poked them, charter schools also have many defenders — including deep-pocketed donors and state lawmakers — who are eager to do battle.

In early 2014, Fariña and de Blasio tried to block three schools in a high-performing charter network from moving into city buildings. That fateful decision sparked a campaign by charter advocates — financed by wealthy donors and national philanthropies — that resulted in a new state law forcing the city to provide charters with building space or funding.

But charter backers didn’t stop there. They continued to jab Fariña and de Blasio at every turn, organizing parents to rally against policies they opposed, and even attacking them on issues unrelated to charters, such as school discipline. With little control over the charter sector or its powerful allies, the mayor and chancellor found themselves in a longstanding feud with foes they had little chance of defeating.

Newark’s charter sector could prove an equally fearsome adversary for León. It serves a larger share of students than New York’s — 33 versus 10 percent — and gets financial support from some of the same national donors. And in recent years, the sector has become more politically active, with schools encouraging parents to vote and charter supporters backing candidates in school-board elections.

But even though charter schools compete with the district for students and funding, León does not appear eager to confront them. In fact, in an interview with Chalkbeat last week, León took pains to praise the innovations of several charter networks and said district and charter schools should share best practices.

Eventually, some school board members may urge him to take a tougher stance on charter schools – perhaps pushing him to block them from renting additional space in district buildings or to revamp the combined district-charter enrollment system.

But, for now, he seems to have decided that it would be counterproductive to pick a fight with a sector whose growth he can’t control (the state approves charter expansions), and whose families often also have children in district schools. Whether he realizes it or not, he’s already steering clear of a conflict that dogged Fariña’s administration for years.

“We’re going to work together to help children in Newark do better,” León said in the interview, “better in all of our schools.”

The honeymoon ends quickly — so enjoy it while it lasts.

Many New Yorkers rejoiced when Fariña was named chancellor.

Educators, who often referred to the new chancellor as “Carmen,” delighted in her pledge to bring joy and dignity back to their profession. Parents celebrated her vow to de-emphasize standardized tests and to boost arts education.

But, as every elected official learns, the goodwill fades fast.

Within weeks of starting the job, Fariña angered many district parents by downplaying a blizzard that snarled families’ commute to school, and later upset charter school supporters by suggesting that they push out unwanted students. Later, some principals would complain she had curtailed their autonomy, while advocates accused her of ignoring the school system’s pervasive segregation.

For now, León is savoring his honeymoon phase as congratulatory messages pour in and warm applause greets him on school visits. But he’s already planning for the difficult work ahead.

He has begun meeting with district officials to take stock of existing programs and budget items, which he will have to decide to keep or scrap when he takes over next month. And in last week’s interview, he promised to meet regularly with community members — though he warned that not everyone will agree with his decisions.

Soon, he will also have to manage the expectations of the newly empowered school board members and, most likely, the power brokers who backed their campaigns. It is a part of the job that his state-appointed predecessor and the mayor-appointed Fariña never had to deal with.

“It’s a challenge,” said Domingo Morel, a political science professor at Rutgers University-Newark. “But that’s the challenge of democracy.”