The map below shows the age of the world's state leaders on 12 December 2017.
The mean age is around 62 years, ranging from 31.5 year old Sebastian Kurz in Austria—whose party won the last legislative elections and is in the process of forming a government—to 91.5 year old President Essebi in Tunisia.
The data come from the REIGN leader data, which in part builds on and updates the Archigos leader data, a dataset of the leaders of the world's independent states from 1875 on. You can find a list of the leaders that are shown in the map on github here.
Note that these data code the de facto, effective leader of a state, so the person listed there may not be the theoretical, de jure head of a state. For example, in parliamentary democracies the prime minister is coded as the state leader even though usually another person is the official, ceremonial head of state, while in semi-presidential regimes with both a president and prime-minister either might be designated the effective leader, and that designation might change in over time if the relative power of the two offices is altered. Similarly, in Russia Putin is coded as the uninterrupted leader since 2000, even for the period when Medvedev was president and Putin prime minister. The websites linked above both have code books that explain coding criteria in detail.
The map was made in R using ggplot2, cowplot, and sf, with data via cshapes and rnaturalearth. The code is on github.
Are leaders in larger or less democratic countries older?
Estonia, where I live, has had a successsion of young prime ministers in their 30s, and the youngest leader on the map is in another small country, Austria. Maybe it is easier for young persons to rise to the top government position in a small, less populous country with less hierarchy. Similarly, if we think of Robert Mugabe's recent retirement, maybe regime type also plays a role in how old a state's leader is.
First, here is leader age against country population, taken from the World Development Indicators:
There is pretty much no relationship at all.
Next, leader age against an index of liberal democracy, from the Varieties of Democracy project (V-Dem):
There is a very slight pattern of younger leaders in more democratic regimes here, but it doesn't really explain much of the variation in age.
Who are those really young leaders in really autocratic states? The list of current under 40 autocrats consists of Kim Jong-Un in North Korea at 34 (more or less, depending on who you ask), Sheikh Al Thani of Qatar at 37, and Saleh Ali al-Sammad of the Houthis in Yemen, at 38 (although you could argue who really is at the top in Yemen right now, if anyone).