For many painful weeks, President Trump treated the coronavirus as he had so many adversaries through more than half a century in the public spotlight: He denied reality, he danced around the facts, he attacked with bluster, and above all, he tried to work his marketing magic: Everything will be okay, the virus will go away, America can get back to business, I am doing a great job. It was standard-issue Trump, a message delivered with his lifelong confidence that he would get the result he wanted by spurning the experts, breaking the rules and declaring his own success.

Marc Fisher @mffisher a senior editor at The Washington Post, is a co-author of “Trump Revealed: The Definitive Biography of the 45th President.

Trump is Trump because he is perceived by many as someone who gets things done, or at least gets what he wants, by ignoring the boundaries that hem in most everyone else — Congress’s procedures, the bureaucracy’s hierarchies, the law’s intricacies, the media’s scruples, the public’s sensitivities. He is always in search of the shortcut.

From his earliest days as a real estate developer through his first three years as president, Trump stuck with a formula: a constant patter of provocation, pride and preening, all in service of finding the quickest path to a claim of victory. “Anytime any obstacle came up, he told us to ignore it, whether it was a building department citation or politicians denying permission for something,” said Barbara Res, who spent 18 years as Trump’s top construction executive. “ ‘Just do what we need to do,’ he’d say. . . . Back then, the worst thing that could happen was a fine. Now, it’s people’s lives.”

Those high stakes, and the president’s inability to bend the coronavirus to his will, finally forced a course correction Tuesday. Unlike at nearly every other turn in his singular American life, there would be no shortcut this time. By telling Americans to stay home and by accepting scientists’ dire projections about how many will die, Trump bowed to reality. The man who rose to the most powerful position in the world by ignoring rules and subverting norms seemed at last to have conceded that there can be no end run around this pathogen.

Trump’s reflex to barge through barriers was honed throughout his upbringing. His father, developer Fred Trump, taught him to always be a “killer,” to act like a “king” and to do what it takes to get the result you seek. His mentor, New York lawyer Roy Cohn, pressed him to break whatever eggshells, rules and even laws stood in his way, and to deal with any pushback later, mainly by aggressively attacking whomever sought to enforce the rules. His pastor, Norman Vincent Peale, preached a theology of success through confidence and an absolute refusal to give in to failure or opposition.

One of Peale’s rules was to “depreciate every so-called obstacle.” In his bestseller, “The Power of Positive Thinking,” he counseled readers to “formulate and stamp indelibly on your mind a mental picture of yourself as succeeding. Hold this picture tenaciously. Never permit it to fade.” Peale, who officiated at Trump’s first wedding, left him with the conviction, as Trump once said, that “the mind can overcome any obstacle.”

When he ran into trouble, Trump’s top executives often marveled that he seemed unbothered by possible consequences, even by bankruptcies and embarrassing business collapses. Instead of buckling down and building companies to last, Trump became an inveterate launcher of enterprises, many of which quickly failed. Even as his lawyers and finance guys stayed up late searching for solutions to his problems, Trump had already moved on, in search of the next shortcut to easy money.

WASHINGTON, DC - MARCH 27 : President Donald J. Trump speaks with members of the coronavirus task force during a briefing in response to the COVID-19 coronavirus pandemic in the James S. Brady Press Briefing Room at the White House on Friday, March 27, 2020 in Washington, DC. (Jabin Botsford/The Washington Post)

In later decades of his career, he mostly stopped creating new businesses, instead renting out his name to enterprises owned or run by others. A trail of lawsuits followed Trump across his licensing empire — from people who’d lost deposits on condos that were never built and from students who paid for Trump-branded seminars that were unaccredited. Trump denied any responsibility for whatever had gone wrong, saying he had only loaned his name to the ventures. “He doesn’t think the rules apply to him,” Res said.

When Trump Tower went up on New York’s Fifth Avenue, Trump got permission to exceed height limits by 20 stories in exchange for making the building’s atrium a public space where anyone could hang out. But when homeless people began spending their days sitting on the lobby benches, Trump ordered the benches covered with large planters, so no one could sit on them, Res said. She reminded him that the law required the amenities he had committed to. “He told us, ‘Don’t worry, what’s going to happen?’ ” Res recalled. “ ‘Who’s going to go after me?’ ” (Trump’s company was indeed fined. The benches came and went through the years.)

In his constant search for shortcuts, Trump is happy to ignore or even attack the experts who offer him advice. Only he knows the right answer. In his book “Think Like a Billionaire,” Trump wrote that when he makes big decisions, “I try to step back and remember my first shallow reaction. The day I realized it can be smart to be shallow was, for me, a deep experience.”

As the coronavirus crisis unfolded, Trump felt comfortable short-circuiting top public health officials — touting a possible “miracle” cure and announcing that he hoped to have the country open for business by Easter — because he believed he had an instinctive grasp of science and medicine. “Every one of these doctors said, ‘How do you know so much about this?’ ” Trump said. “Maybe I have a natural ability. Maybe I should have done that instead of running for president.”

Trump’s shortcuts sometimes involve considerable savvy, but much of the time they are characterized more by moxie and hard knuckles. In the 1980s, for example, to expedite the long, difficult process of acquiring land to launch his first casino-hotel venture in Atlantic City, he made a deal with two men who were eventually banned from the casino industry by state authorities; one was an organized-crime figure who was later targeted for a hit.

Of course, Trump’s drive to find a shortcut often falls flat. He pulled out of the nuclear pact with Iran, promising to cut a new deal. It never happened. He broke with the consensus of several previous presidents and met with North Korea’s dictator, Kim Jong Un, saying he could achieve denuclearization of the rogue country. Never happened. He promised to build a border wall with Mexico and force the Mexicans to pay for it. Never happened.

Trump’s frequent assurances that a big win is just over the horizon are designed primarily to make a splash. “I play to people’s fantasies,” he wrote in “The Art of the Deal.” “People may not always think big themselves, but they can still get very excited by those who do.”

His supporters testify to that. So does the media attention he commands. “If you are a little different, or a little outrageous, or if you do things that are bold or controversial, the press is going to write about you,” Trump said in that 1987 bestseller — and he proved his case in his 2016 presidential campaign. Even in this most serious of crises, Trump has tweeted that “the ‘Ratings’ ” for his news conferences about the coronavirus are “so high.”

The epidemic has once again solidified Trump’s place in the spotlight, but he hasn’t found the shortcut to success — a return to health for the nation’s people and economy — that might ensure his reelection.

For weeks, Trump was visibly frustrated by the pleas for caution and patience coming from the government’s top health experts, such as Anthony Fauci and Deborah Birx. The president leavened their messages of deep concern with his own Panglossian declarations that everything would be just fine, and very quickly.

He touted off-label, unproven cures. He was sorely tempted to declare victory and send people back to work by Easter, even as the virus felled thousands of Americans. Trump “really believes a lot of his own bullshit,” Res says. “And he acts on it: Once he made up his mind to do something his way, Fauci and Birx could stand on their heads and it wouldn’t matter.”

But for all Trump’s confidence in his own decision-making, he also has a lifelong history of quietly backing down when his plans turn out to be duds. He almost never admits fault, but he does change course — often quite dramatically: He switched his party affiliation five times, from Democrat to Republican to Reform Party and back again; he shifted his public position on abortion from “very pro choice” in 1999 to calling in 2016 for criminal punishment for women who have abortions.

In the case of the coronavirus, he went from pushing to reopen the economy to extending the shutdown without ever saying he’d given up on his shortcut. He simply pivoted, as if all of his previous statements had been annulled. His tone changed, at least for a couple of days, becoming more sober, even somber.

And yet, just as abruptly, he once again used his daily virus briefing on Tuesday to vent his frustration with governors who wanted more ventilators, and on Wednesday to question whether doctors and nurses really need so many masks and gowns. (“How could they possibly use so much?”)

For the moment, though, Trump has embraced the advice of the scientists he had previously branded as overly cautious. He is now, he says, “a wartime president.” It might take a little longer, but he can see victory not so far away. He guarantees it.