Well, for starters, there are a couple of inherent problems with all of the above statement your professor espoused, not least of which some underlying difficulties with just the way it's all phrased, leading me to question some of the assumptions being made.
The biggest of which is this idea that males "always" die sooner bcs testosterone somehow takes away from your immune system. Ignoring, just for a moment, that women also have this hormone present in their bodies - if in lesser quantities, this is the first time I've ever heard the human body represented as a closed system with a zero sum setup.
There is no taking energy from one system to give to another, least not in the way your professor implying. We don't experience a trade-off in our immunity for having more muscles. You could in fact argue the opposite, based on the fact that most people who exercise regularly - thereby toning muscles and the like, adding to those "systems" if you will - generally have stronger immune systems than those who don't. Hence one of the reasons why exercise is important.
Moreover, no reputable scientist ever offers up statements in absolutes like that. Statistically speaking, men are more likely to die sooner than women, but this does not mean that *every* man will die before *every* woman. A lot of this is also dependent on the fact that historically men have had more dangerous occupations that carry more threat of risk, and they tend to engage in more dangerous risk behaviors, as a general rule. Now, some of this ties into hormones and the like, but you cannot make cut and dried casual statements the rely on a single factor when there are multiple forces at work.
Also, this depletion of energy - while I have heard similar theories with a more biological basis, such as there are only so many times the muscles can perform a certain action just because of wear and tear - but this would seem to me to be a modern conceit, something only applicable when we're living long enough in the first place to age to the point where our bodies give out. Life expectancy has jumped dramatically in the past several hundred years, and dying of natural causes is far more prevalent than it used to be. (Hence Hobbes' quote on life being nasty, brutish, and *short*.)
As such, it doesn't explain historical trends of differing life expectancies between the sexes, if neither sex is living long enough for this supposed energy depletion to kick in.