One main theme of "Leiningen Versus the Ants" is persistence; Leiningen refuses to back down in the face of a natural destructive force, and although he suffers, he wins out in the end:
The sporting zest with which the excitement of the novel contest had inspired him the day before had now vanished; in its place was a cold and violent purpose. He would send these vermin back to the hell where they belonged, somehow, anyhow.
(Stephenson, "Leiningen Versus the Ants," classicshorts.com)
Leiningen believes that his human intellect is more powerful in potential than the irrational, mindless force of the ants. Despite some setbacks, Leiningen continues to fight and plan for new situations. At the start of the story, the District Commissioner tells him of the ants and their destructive abilities; Leiningen accepts his advice and chooses to act rather than flee. As the ants overwhelm his defenses through their sheer numbers, he finds more and better ways to attack them; finally, although he is badly wounded, he unleashes the river and wipes the ants out, showing his persistence in the face of seemingly unstoppable odds.