It’s nice work if you can get it, with fairly good pay, fringe benefits and a pension. So how do you become an Afghan general?

Some of them have climbed the command ladder for decades, working hard and surviving purges by successive governments. But others took much easier routes.

Suppose you are the young son of a former warlord who has just died. Along with condolences, the government will make you a general, as if the rank were hereditary. Commissions are also handed out as political thank-yous to male relatives of important figures. And in the golden age of general-making — the 1990s civil war — they were sometimes distributed in lieu of pay.

In the anarchy that followed the Soviet withdrawal and the fall of the Communist regime, hundreds of generals were born overnight. Sibghatullah Mujadidi, the interim president of the mujahedeen government, which was backed by the Central Intelligence Agency, had little to offer the disheveled fighters who crowded his waiting room, so an aide kept note of whoever asked to become a general.

According to Abdul Hafiz Mansour, who ran state television at the time and is now a member of Parliament, a confidant of the president — often his son — would turn up at the studios every evening to hand the news anchor a list of new generals to declare. One night, he said, there were 38 names.