Statistics...
11% to 27% to 21% in 3 years? I think counting might be part of the issue there.
The years being 2021, 2023 and 2024, I imagine increase from 11% to 27% during the two years 2021-22 was in part due to COVID - losing employment or taking earlier retirement, working from home, and having spare time during the restrictions of 2019-21.
The decrease from 27% to 21% might reflect return to office, increasing demands of work or better (more demanding) jobs, and the loss of the cohort of 65 yo (b. 1959) in 2024 weren't replaced with incoming 44 yo (b. 1979.)
For 0-25 yo the corresponding stats 25%, 12% and 10%. So the 26-45 (+66-99) yo numbers are 64%, 61% and 69%.
While these percentages are ratios it is curious the 26-45 yo (plus the superannuated :) ratios are pretty static. Generally this group are more disciplined than the youngsters but with the spark and creativity that age often blunts.
Absolute (raw) numbers might be more enlightening.
I suspect programming and computing, AI perhaps excepted, are not particular "sexy" for the cohorts < 25 yo. as I am guessing that the area doesn't pay all that well now and job security is non-existent. Most of IT (contrast computer science) is pretty dull and unchallenging for talented individuals who would find more rewarding and profitable uses for their time.
I suspect individuals who develop code for their own use or as peripheral aspect of their employment (where the employer has surrendered any interest in that code) will continue to dump their code on github etc with a CC0 or BSD or GPL-x licence so that any interested party can do pretty much anything with it (CC0, BSD) including maintaining it.
Large cornerstone projects like openssl probably can only continue in the long term with commercial funding or support. I don't know what proportion of the core Linux kernel developers are employed by firms using the Linux kernel in their businesses but is probably quite significant. If the proportion of volunteers on such projects decreases very much, the independence and freedom (libre) of the projects would be imperiled.