There was one leader in history who did precisely those great things that we expect our leaders to do, so much so that he became well-known for centuries after he had passed away. This leader was called Dhul Qarnain, and the Prophet (صلى الله عليه و سلم) was questioned about him:
“And they will ask you about the Two-Horned One. Say: “I will convey unto you something by which he ought to be remembered.” [18:83]

The fourth and last story that Allah has narrated in Surah Al-Kahf is about this just, Allah-fearing ruler and his conquests. Several Quran exegeses shed light upon why Allah refers to him as ‘Dhul Qarnain‘, or “the possessor of (ذِي) the two horns (الْقَرْنَيْنِ)”.
A Great Leader
It is well-known that a very small percentage of mankind go on to become leaders who rule over their masses. Yet, those who do, exercise considerable influence (good or bad) during their tenures. This story of Dhul Qarnain that Allah has narrated in the Quran serves to be a beacon for anyone who occupies or intends to ascend to, a position of authority and leadership over a large number of people.
Dhul Qarnain was so successful in influencing his subjects, that he was able to convince them to submit to and worship Allah as the only god,- and he did this without shedding any blood!
A Highly Resourceful Man
“Behold, We established him securely on earth, and endowed him with [the knowledge of] the right means to achieve anything [that he might set out to achieve];” [18:84]
Allah had bestowed every kind of resource and means (سَبَبًا) upon Dhul Qarnain, which Tafsir Ibn Kathir describes as knowledge. This is what the word سَبَبًا means, according to Ibn Abbas, Sa’eed Bin Jubair, Qatadah, `Ikrimah and Al-Suddi, among others.
The tafsir further expounds on the meaning of وَآتَيْنَاهُ مِن كُلِّ شَيْءٍ سَبَبًا: “Allah gave him the means of all things, meaning, the means and power to conquer all areas, regions, and countries, to defeat enemies, suppress the kings of the earth and humiliate the people of shirk. He was given all that a man like him would need.”
So, we can conclude that Allah had blessed Dhul Qarnain with knowledge as well as the worldly power, authority and physical means necessary to become a conqueror who established the sovereignty of Allah upon earth where ever he went.

Establishment of Justice
“And he marched westwards till, when he came to the setting of the sun, it appeared to him that it was set in a dark, turbid sea; and nearby he found a people [given to every kind of wrongdoing]. We said: “O you Two-Horned One! You may either cause[them] to suffer or treat them with kindness.” [18:86]
Dhul Qarnain came upon townspeople who lived near the sea because when the sunset upon these people, it appeared to them to be going down into the sea.
Allah granted Dhul Qarnain complete authority and power over these people, which is obvious from the second part of the verse above. He could punish them for their crimes, or he could treat them with kindness –  Allah had given him the power, as their sovereign, to do as he wished.

Moving Past a Barren Land
“And once again he chose the right means[to achieve a right end].” [18:89]
Dhul Qarnain traveled further on, using his resources and knowledge, as before.
“[And then he marched eastwards] till, when he came to the rising of the sun he found that it was rising on a people for whom We had provided no coverings against it.” [18:90]

He came upon a town whose inhabitants had no shade or cover to protect them from the heat of the sun during the day i.e. there were no buildings or trees.  Qatadah said, “It was mentioned to us that they were in a land where nothing grew, so when the sun rose, they would go into tunnels until it had passed its zenith, then they would come out to go about their daily lives and earn themselves a living.”
(Tafsir Ibn Kathir)

Helping a Tormented Nation
“And once again he chose the right means(to achieve a right end).” [18:92]
“[And he marched on] till, when he reached[a place] between the two mountain-barriers, he found beneath them a people who could scarcely understand a word [of his language].” [18:93]
Once again, Dhul Qarnain marched on along routes of the earth, until he came upon a people dwelling in a mountainous terrain. They couldn’t understand his language but managed to convey to him one of their pressing problems
“They said: “O you Two-Horned One!Behold, Yajuj and Majuj are spoiling this land. May we, then, pay you a tribute on the understanding that you will erect a barrier between us and them?” [18:94]
Unlike the barren land that Dhul Qarnain had last come across, the mountainous land on which this nation lived was undoubtedly a good one, because of which its inhabitants sought a permanent solution from the corruption being wrought upon it by the Yajuj andMajuj, who’d intermittently attack and plunder them.
This indicates the righteous nature of these people, because only those who are morally upright and Allah-fearing are sensitive to and intolerant of vice, and seek to eradicate it from their communities.
A Job Well Done

”Bring me ingots of iron.” Then, after he had [piled up the iron and] filled the gap between the two mountain-sides, he said: “[Light a fire and] ply your bellows.” At length, when he had made it [glow like]fire, he commanded: “Bring me molten copper which I may pour upon it.” [18:96]

Dhul Qarnain got to work. Using iron, fire, bellows, and molten copper, he utilized the knowledge, manpower and other resources at his disposal to build an insurmountable and impenetrable barrier (رَدْمًا) that trapped the Yajujand Majuj in the valley between the mountains.

One point I noted is that when the townspeople asked Dhul Qarnain to build a barrier for them, they called it (the Arabic word) سَدًّا. This word means, “any construction or building with which a place is closed up or stopped. A thing intervening as a separation, a partition, a fence, a barrier, a rampart, or an obstacle or obstruction between two other things.” [Lane]

When he agreed to do the job, however, Dhul Qarnain called this barrier (the Arabic word) رَدْمًا, which means, “A thing intervening between two other things, preventing the passage from one to the other; an obstruction, or a barrier; any building with which a place is obstructed. It is larger than a سَدًّا and signifies anything having parts that are put, and then joined and sewed, one upon another.” [Lane]

Analysis of these Arabic words reveals that Dhul Qarnain built for the people a barrier that was bigger, better, firmer and more long-lasting on purpose than what they had requested. The markings of a true “professional”! -Someone who does his job better than expected. The next verse corroborates this fact:
And thus [the barrier was built, and] their enemies were unable to scale it, and neither were they able to pierce it.” [18:97]

The barrier was so hard, firm and sturdy, that the Yajuj and Majuj were unable to even pierce a small hole in it, let alone scale it over the top to come bother the good townspeople again.
Dhul Qarnain fulfilled his promise to the people – he worked hard to create a huge metal barrier that prevented the Yajujand Majuj from reaching them to plunder and loot again.