Getty Images

The memorabilia has been bubble-wrapped—the autographed Willis Reed print, the kitschy poster from the 1978 Finals. A brawny typewriter, the Royal 440, rests on the radiator. An NBA staff guide, dated 1975-76, peeks out from a shelf.

And on the desk sits a yellowed Rolodex, jammed with four decades of key NBA figures. But the real power rests beside the Rolodex.

That's where the PC is. The one with the spreadsheet containing all those arena dates and television commitments and grudge matches. The one that dictates where every NBA team will play, and when.

For the last 30 years, Matt Winick has punched the keys on this PC (or one like it) and arranged all of those dates, color-coding for home games (blue) and away (red), agonizing over every six-game road trip and every back-to-back set, bracing for the complaints that were sure to follow.

"I tell the teams, 'Hey, that's the way the computer did it,'" Winick said from behind his desk. "But it was never the computer. I was the computer."

Officially, Winick has carried the title of senior vice president, but he is best known as the NBA's Scheduling Czar—a role he alone has held since 1985, a role he is now relinquishing for good.

Courtesy of the NBA

The 75-year-old Winick, who first joined the NBA in 1976, is stepping down (not retiring, he insists) at the end of the month, taking with him four decades of memories, mementos and scheduling wisdom.

The spreadsheet has been bequeathed to Tom Carelli, the league's senior vice president of broadcasting. Carelli's team produced the recently released 2015-16 schedule, the first without Winick's fingerprints since the 1984-85 season.

"I always described it as a jigsaw puzzle with 1,230 pieces"—one for every game—"and if one of them doesn't fit, it doesn't work," Winick said. "All 1,230 pieces have to fit."

There is a mix of pride and wistfulness and relief in his voice, all filtered through a New York accent. There's nothing like the satisfaction of finishing a puzzle. Nor the stress of getting there. The puzzle is critical, fascinating, complex. The puzzle is a headache.

The best part of the job?

"Getting it done," Winick said with a prolonged chuckle and a snort. "I don't know if it made up for the four months of agony. But it was a helluva great day, I'll tell you."

There might not be a more complex or thankless job in professional sports than that of schedule-maker—and the complexity and thanklessness might be double in the NBA because of the competition for arena dates and the sheer impossibility of producing a calendar that seems equitable across 30 teams.

Every franchise plays 41 home games and 41 road games. But from there, the schedules can diverge wildly.

Last season, the Detroit Pistons played 22 back-to-back sets (games on consecutive nights), while the Miami Heat had just 16. The Portland Trail Blazers—on a virtual island in the Pacific Northwest—will always travel more miles than the Cleveland Cavaliers. Every year, some teams will benefit from a greater "rest" advantage—i.e. more days off between games than the opposition—over the course of a season.

The NBA might have the quirkiest and the most scrutinized schedule in pro sports. Its release each summer is highly anticipated and inevitably greeted with distressed howls from teams and fans.

"Ten road games in November? We got hosed!"

"Twenty-two back-to-backs? Are you serious?"

"Man, our schedule in (fill in a month) is brutal."

At some point, every team executive has called Winick to lodge a complaint.

Mary Altaffer/Associated Press

"Every year, he would respond the same way," said Brooklyn Nets general manager Billy King. "'You have to play 41 at home and 41 on the road.'"

It's not quite that simple, of course. But Winick's wry retort has the benefit of being generally true. Whatever angst a team expresses over, say, a road-heavy November, it will necessarily be offset later in the season, perhaps by a home-heavy April—which, of course, will cause that team's closest rival in the standings to complain.

"Put it this way: I never expected anyone to call me and say thank you," Winick said.

See, it is literally a thankless job. And one that Winick never expected when he joined the NBA in 1976, as director of media relations.

NBA Photo Library/Getty Images

The NBA had just 22 teams then. Winick was one of 20 full-time employees in the league office. The schedule was handled by the legendary Eddie Gottlieb, who would painstakingly construct the entire thing by hand, on a yellow legal pad. The league later hired an outside firm to computerize the schedule.

In 1985, Scotty Stirling, the NBA's vice president of operations, pulled the job back to the league office and assigned it to Winick.

"We need to bring it in-house," Stirling told Winick. "And you'll have a lifetime job here."

Lifetime job?

"Nobody else wants it," Stirling said.

Winick lets the line hang in the air for a moment, then chuckles and snorts again.

"So the lifetime job lasted a long time," he said.

Every year brings different obstacles and off-the-wall requests. Winick once had an owner lobby him not to schedule his team a specific weekend.

"Why? It was the owner's son's bar mitzvah," he said, chuckling. "How do you put that in a computer?"

Another year, a head coach asked Winick to give his team more home games on the first night of a back-to-back. Winick did his best to accommodate him. The coach got fired before the new season began and landed with a divisional rival.

The next time the two crossed paths, the coach groused that his old team had a better schedule than his new team.

"I said, 'Look, you sonofabitch, I gave you what you wanted! I didn't tell you to get fired!'" Winick recalled with a smile and laugh.

There was much less scrutiny in the early years—no Internet, no social media, no one compiling "rest" data—but the challenges were greater. The NBA was a second-tier league, fighting just to get dates in its home arenas. Even at the Boston Garden, during the Larry Bird era.

Dick Raphael/Getty Images

"They took us reluctantly," Winick said of the Garden, which was run by the NHL's Bruins. "We were a pain in the ass. It disturbed a Bruins practice that the Celtics had to play a game or something. … We'd fight over playoff dates, we'd fight over everything. I remember going to a playoff game that we had to play on like a Tuesday afternoon, because that was the only date we could get up there."

There are few such battles today, with the NBA now a multibillion-dollar global enterprise, its games in high demand. There are more teams, of course, and more national television obligations and more variables at work. Though Winick's spreadsheet had some constraints built in—disallowing a double-booking, for instance—it was not automated; Winick assigned all 1,230 games himself, through a painstaking process that took months.

"You go to sleep thinking about: How can I get this team to here?" Winick said. And sometimes the answer would hit him at 3 a.m., stirring him awake.

It's all changing now, with new hands at the controls and more advanced software driving the process. More automation, more algorithm-driven scheduling, less human touch. An era is coming to a close at Olympic Tower.

Elsa/Getty Images

On this day, Winick's 16th-floor office is cluttered with boxes and bubble wrap and dusty reference guides. The signed Willis Reed print was a gift from Reed, who was a Knicks rookie when Winick worked for the team.

The real historical gem? A red binder titled "Operations Manual" and dated 1982. The pages appear hand-typed, with a Dewey Decimal index and sections dedicated to uniform requirements and travel guidelines and fine structures ($100 for a technical foul). Winick believes it's the first such manual the league produced.

The binder and the media guides are destined for the NBA archives, to be preserved for posterity. And Winick? He isn't quite ready to be archived, believing there are still leagues out there that could use the skills he's honed these last 30 years.

"I'd like to consult," he said. "I'd like to be able to impart my wisdom."

It could be a minor soccer league in New Jersey. It could be the CYO league down the street.

"I need to have a reason to get up in the morning," Winick said.

Soon, the NBA's Scheduling Czar will head home to Baldwin, Long Island, with only one calendar left to fill: his own.

Howard Beck covers the NBA for Bleacher Report. Follow him on Twitter, @HowardBeck.