It sounds like the setup for a joke: So Dennis Rodman and the leader of North Korea are watching a basketball game …

But this was no joke, except in the cosmic sense. There, in the capital Pyongyang, the eccentric former Chicago Bulls star known as “the Worm” was in the stands with Kim Jong Un, the two chatting like long-lost fraternity brothers.

The only thing that could have made the tableau more bizarre would be to include Donald Trump, which Donald Trump proceeded to do. Scoffing at those questioning Rodman’s judgment — which, to be fair, seems to have no other purpose but to cause people to question it — the opinionated tycoon defended the visit from afar.

“You look at the world; the world is blowing up around us,” he said on Fox News. “Maybe Dennis is a lot better than what we have.” Secretary of State John Kerry may not grasp that the great failing of American diplomacy is it doesn’t make enough use of people who used to be married to Carmen Electra.

Not everyone is unhappy that Rodman went to North Korea. Many are unhappy only because he came back. Others, however, find it absurd that anyone would care about the foreign travels of an aging ex-jock known less for his athletic exploits than for his neon hair colors, willingness to don a wedding dress, and voluminous array of tattoos and piercings.

Is the whole affair absurd? Maybe so, but no more than anything else about North Korea, whose people could hardly be more isolated from the rest of the world if they lived on Mars.

Kim Jong Un is the latest ruler produced by what might be called monarchical communism, having inherited the seat of power at age 27 or 28 (his birth date is not firmly established) from his father Kim Jong Il, an obsessive Elvis Presley fan given to wearing platform shoes.

Rodman’s visit provokes interest mainly because he is one of the few Americans to meet Kim and report back. “He wants Obama to do one thing, call him,” attested Rodman, who said Kim also told him, “I don’t want to do war.”

This revelation was a bit surprising coming only days after Kim’s regime announced that if the United States and South Korea held joint military exercises, their forces would face “miserable destruction.”

But what Kim really thinks is largely a mystery. One former State Department official marveled, “There is nobody at the CIA who could tell you more personally about Kim Jong Un than Dennis Rodman, and that’s scary.”

Scary because Kim heads a government that rules 25 million people with a bizarre mix of economic idiocy, inhuman repression and complete fantasy. A biography of the young dictator claims he wrote 1,500 books as a university student.

Oh, and also scary because he has nuclear weapons, which the regime occasionally threatens to put to use.

“He loves basketball,” said Rodman. “I said, ‘Obama loves basketball.’ Let’s start there.”

Who says a visit by a retired NBA veteran and the Harlem Globetrotters can’t lead to a thaw in relations between Pyongyang and Washington?

In 1971, an American table-tennis team playing in Japan was unexpectedly invited to visit China, which at the time much resembled today’s North Korea. The team accepted, launching what became known as ping-pong diplomacy. The following year, Richard Nixon became the first American president to visit the People’s Republic.

Maybe the courtside encounter will have a similar outcome. Maybe Kim was so taken with Rodman — or so alarmed — that he’ll decide to make peace with the Americans. If it happens, we can call it worm diplomacy.

Sure, it’s improbable. But we’re talking about Rodman and North Korea: Everything about them is improbable.

And if that doesn’t work? We can always send Trump.