According to Bible Jehoram was 32 years old when he became king and died 8 years after at the age of 40.
Immediately after Jehoram's death, his son Ahaziah became king.
"And the inhabitants of Jerusalem made Ahaziah his youngest son king in his stead: for the band of men that came with the Arabians to the camp had slain all the eldest. So Ahaziah the son of Jehoram king of Judah reigned."
"Forty and two years old was Ahaziah when he began to reign, and he reigned one year in Jerusalem. His mother's name was Athaliah the daughter of Omri." (2 Chronicles 22:1-2)
NOTE:
Father died at age 40 years old and immediately son aged 42 years old took over the reign.
How is it possible for the son to be older than his father by 2 years
The issue
is difficult to resolve. Let’s say Jehoram was 32 when Ahazia was born in order
for him to reach 42 would be 30 years. No Kingdom would have a time gap of 30
years without a King to fill. This would mess up the whole chronology timeline
if there was such a gap which is not historical. Let's say Jehoram was 10 years
old when Ahazia was born, this would still leave a 12-year gap between the time
Jehoram passing and Ahazia taking the throne.