
181 Ill. App.3d 821 (1989)
537 N.E.2d 875
THE PEOPLE OF THE STATE OF ILLINOIS, Plaintiff-Appellee,
v.
GREGORY TATUM, Defendant-Appellant.
No. 1-87-3108.
Illinois Appellate Court  First District (3rd Division).
Opinion filed March 29, 1989.
*822 Mary Ellen Dienes, of Chicago, for appellant.
Richard M. Daley, State's Attorney, of Chicago (Inge Fryklund, Jerry D. Bischoff, and Kathleen T. Kavanagh, Assistant State's Attorneys, of counsel), for the People.
Judgment affirmed.
PRESIDING JUSTICE FREEMAN delivered the opinion of the court:
After a bench trial in the circuit court of Cook County, defendant, *823 Gregory Tatum, was convicted of the offense of possession of a controlled substance. After a second bench trial in the same court, defendant was convicted of the offenses of delivery of a controlled substance and possession of a controlled substance. He was sentenced to two years' imprisonment on the former possession offense and a concurrent 10 years' imprisonment on the delivery offense. Defendant appeals only the 10-year sentence for the delivery offense.
Defendant's first trial, on one count of possession of a controlled substance, 3.48 grams of heroin, with intent to deliver, a Class 2 felony (Ill. Rev. Stat. 1983, ch. 56 1/2, par. 1401(c)), resulted from his arrest by Chicago police officers on January 23, 1985. The trial court deferred sentencing, at defendant's request, after finding him guilty of the lesser-included offense of possession of the heroin, a Class 1 felony. Ill. Rev. Stat. 1983, ch. 56 1/2, par. 1401(b).
Defendant's second trial, on one count of possession of a controlled substance, one gram of heroin, with intent to deliver and one count of delivery of a controlled substance, 24.47 grams of heroin, a Class X felony (Ill. Rev. Stat. 1983, ch. 56 1/2, par. 1401(a)), resulted from his arrest in April 1985, while he was on bond on the January offense. The trial court found defendant guilty of the delivery offense and the offense of possession of one gram of heroin.
At defendant's sentencing hearing, the State recommended sentences of three years on the possession offense, resulting from defendant's first trial, and seven years on the delivery offense, to be served consecutively to the former sentence. The State apparently based its recommendation of consecutive sentences on section 5-8-4(h) of the Unified Code of Corrections (Code), which provides that any sentence imposed upon conviction of a felony committed while on bond on a prior felony charge "shall be" consecutive to any sentence imposed upon conviction for the prior felony. (Ill. Rev. Stat. 1985, ch. 38, par. 1005-8-4.) After defense counsel pointed out that section 5-8-4(h) was not effective until September 1985, the State recommended that defendant be sentenced to three years on the possession offense and a concurrent 10 years on the delivery offense. The trial court sentenced defendant to two years on the possession offense and a concurrent 10 years on the delivery offense.
On appeal, defendant asserts that the 10-year sentence on the delivery offense violated the Federal constitutional bar against ex post facto laws applicable to the States (U.S. Const., art. I, § 10). Defendant asserts that the trial court patently imposed that sentence only because it could not sentence him to seven years on the delivery offense to be served consecutively to the three-years sentence on the *824 possession offense recommended by the State. Because the 10-year sentence achieved the result the sentences originally recommended by the State would have achieved, defendant concludes that the trial court indirectly applied section 5-8-4(h) retroactively in imposing that sentence.
We cannot agree with defendant's characterization of the record in this case. Nothing in the transcript of the sentencing hearing supports the conclusion that the trial court imposed the sentence appealed from because it could not accept the State's original sentencing recommendations. Defendant notes that the trial court asked the State whether it was withdrawing its recommendation of a consecutive sentence after defense counsel asserted that section 5-8-4(h) was inapplicable to defendant's case. Therefore, defendant asserts, the trial court patently relied on and was guided by the State's recommended sentence on the delivery offense.
Defendant's conclusion is a non sequitur. The fact that the trial court asked the State whether it was withdrawing its original recommendation of a consecutive sentence in nowise reveals that it relied upon the State's second recommendation as to the length of the sentence on the delivery offense. The fact that the trial court never indicated at the sentencing hearing, prior to the State's withdrawal of its original recommendations, that it was inclined to or would follow those recommendations contradicts defendant's argument. Also militating against his argument is the fact that the trial court did not explicitly or implicitly accept the State's recommendation of a three-year sentence on the possession offense.
 1 However, even assuming that the trial court did accept the State's second recommendation as to the sentence on the delivery offense, we do not find that the trial court thereby violated the prohibition against ex post facto laws. As both parties note, the cornerstone of the constitutional prohibitions against such laws is that persons have a right to a fair warning of the conduct which will give rise to criminal penalties and what those penalties will be. People v. Coleman (1986), 111 Ill.2d 87, 93-94, 488 N.E.2d 1009.
 2 For delivering 24.47 grams of the controlled substance of heroin, a Class X felony, defendant could have been sentenced to anywhere from 6 to 30 years, as defense counsel conceded at the sentencing hearing. This penalty, unlike section 5-8-4(h), was in effect at the time of defendant's commission of that offense. (Ill. Rev. Stat. 1983, ch. 56 1/2, par. 1401; Ill. Rev. Stat. 1983, ch. 38, par. 1005-8-1.) Defendant therefore had fair warning of the criminal penalty to which his conduct was subject. The mere facts that, within the 6- to *825 30-year range, the trial court decided to sentence defendant to 10 years and that the sentence accomplished the same result as the State's original sentencing recommendations do not compel the conclusion that the trial court decided upon that sentence for the improper purpose of accomplishing the result which application of section 5-8-4(h) would have achieved.
Moreover, section 5-5-3.2(a)(10) of the Code (Ill. Rev. Stat. 1985, ch. 38, par. 1005-5-3.2) allowed the trial court to consider as an aggravating factor defendant's commission of the Class X felony of delivery while on bond on the Class 2 felony charge of possession with intent to deliver. Subsection (a)(10) to section 5-5-3.2 was added by Public Act 83-1449, effective September 17, 1984. Defendant therefore also had fair warning that his commission of the delivery offense, while on bond on the possession offense, could subject him to more than the statutory minimum of six years for commission of the delivery offense. This conclusion leads us to defendant's first alternative argument.
 3 Defendant asserts that the trial court might have properly decided that the sentence on the delivery offense should be seven years, as recommended by the State, plus an additional number of years representing the possession charge, in recognition of defendant's commission of the former felony while on bond on the latter, an aggravating factor under section 5-5-3.2(a)(10). However, defendant argues, that additional number of years was limited to the two years the trial court ultimately found to be the appropriate sentence on the possession offense, not the three years originally recommended by the State. Defendant concludes that, in adding three years to the sentence on the delivery offense, the trial court unduly emphasized section 5-5-3.2(a)(10) and thereby abused its discretion.
We find nothing in the record to support defendant's assertion that the trial court decided upon the length of the sentence on the delivery offense by adding to an underlying sentence for that offense an additional number of years to represent the possession offense committed while on bond.
Moreover, section 5-5-3.2(a)(10) allows a trial court to consider the commission of one felony while on bond for another as an aggravating factor in imposing sentence upon conviction of the later felony. It does not, as defendant's argument assumes, allow a court, in consideration of the aggravating factor, to add a sentence imposed on the earlier felony to the sentence imposed upon the later felony. Otherwise, a trial court could punish the same offense twice. As a trial court does not have such authority, it would be illogical for a court of *826 review to hold that the trial court abused its discretion in exercising that authority.
 4 Lastly, defendant contends that the 10-year sentence was also an abuse of discretion because he was a first-time offender with excellent prospects for rehabilitation. He concludes that he was entitled to the six-year minimum and that no more than one additional year should have been added thereto for his commission of one felony while on bond for another.
Contrary to defendant's argument, a trial court is not required to give rehabilitative potential more weight than it gives the seriousness of an offense in its sentencing decisions. (People v. Burke (1987), 164 Ill. App.3d 889, 518 N.E.2d 372; People v. Bunch (1987), 159 Ill. App.3d 494, 512 N.E.2d 748.) As such, we believe the trial court properly exercised its discretion in sentencing defendant.
Specifically, we do not find that, as defendant implies, the trial court was per se required to impose the six-year minimum for a Class X felony because he was a first-time offender. That fact is no more than a mitigating factor which the trial court is to consider along with all other mitigating and aggravating factors. Ill. Rev. Stat. 1985, ch. 38, pars. 1005-5-3.1, 1005-5-3.2.
 5 Moreover, while age is a factor to be weighed in sentencing (see, e.g., People v. Bunch (1987), 159 Ill. App.3d 494, 512 N.E.2d 748), defendant's age, 30, at the time of his offenses, was not so youthful as to be accorded great weight as a mitigating factor. Compare People v. Kindelan (1986), 150 Ill. App.3d 818, 502 N.E.2d 422 (37-year-old defendant), with People v. Anderson (1985), 142 Ill. App.3d 240, 488 N.E.2d 557 (17-year-old defendants), and People v. Steffens (1985), 131 Ill. App.3d 141, 475 N.E.2d 606 (16-year-old defendant).
Neither did the trial court abuse its discretion in giving defendant's employment history and educational background less weight than it gave the fact which they revealed, i.e., that defendant did not come from a disadvantaged background. That is, the trial court properly considered that fact as militating in favor of a greater rather than lesser sentence. The trial court could properly have inferred from defendant's well-paid employment history and his post-secondary education that his offenses were less the result of negative social forces and influences than of personal choice. It thus could have properly concluded that his background revealed less rehabilitative potential than incorrigibility.
 6 In the final analysis, we will not substitute our judgment for that of the trial court by balancing the appropriate sentencing factors *827 differently than that court. People v. Cox (1980), 82 Ill.2d 268, 412 N.E.2d 541.
For all of the foregoing reasons, we affirm defendant's sentence of 10 years' imprisonment for the offense of delivery of a controlled substance.
Affirmed.
McNAMARA and WHITE, JJ., concur.
