
104 P.3d 900 (2003)
The PEOPLE of the State of Colorado, Plaintiff-Appellee,
v.
Mark E. ROCKWELL, Defendant-Appellant.
No. 02CA1812.
Colorado Court of Appeals, Div. III.
December 31, 2003.
As Modified on Denial of Rehearing April 29, 2004.
Rehearing Denied July 29, 2004.
Certiorari Granted January 10, 2005.
*901 Ken Salazar, Attorney General, Katharine J. Gillespie, Assistant Attorney General, Denver, Colorado, for Plaintiff-Appellee.
E. Scott Baroway, Englewood, Colorado, for Defendant-Appellant.
Opinion by Judge TAUBMAN.
Defendant, Mark E. Rockwell, appeals the trial court order denying his Crim. P. 35(a) motion to correct his sentence to reflect that he is subject to a term of discretionary rather than mandatory parole. We vacate the order and remand for further proceedings.
Defendant was originally charged with single counts of second degree burglary of a dwelling, a class three felony under § 18-4-203(2)(a), C.R.S.2003, and third degree sexual assault. The charges resulted from a September 1993 incident in which defendant broke into a home and touched the victim's genitals while she slept.
Defendant entered a plea bargain under which he agreed to plead guilty to the burglary charge in exchange for the dismissal of the sexual assault charge and a two-year deferred judgment with a sentence to probation. The agreement specified that defendant would participate in any offense-specific treatment that the probation department recommended.
The second degree burglary charge originally stated that defendant had entered the victim's home with the intent to commit third degree sexual assault. The charge was amended at the plea hearing to state that defendant entered the home with the intent to commit the crime of harassment.
In April 1994, the trial court accepted defendant's plea, placed him on probation, and ordered "offense specific treatment." Between 1996 and 1999, defendant's probation was repeatedly revoked and reinstated after he violated the conditions of probation by failing to complete sex offender treatment. In April 2000, the trial court revoked defendant's probation for the final time and sentenced him to a six-year term in the Department of Corrections plus a three-year term of mandatory parole under § 18-1.3-401(1)(a)(V)(A), C.R.S.2003.
While imprisoned, defendant filed the motion for Crim. P. 35(a) relief that is at issue here. Defendant argued that, because his crime occurred in 1993 and involved unlawful sexual behavior, he was subject to a discretionary, rather than a mandatory, parole term under the applicable sentencing statutes.
The trial court summarily denied defendant's motion, noting that he pleaded guilty to second degree burglary with the intent to commit the crime of harassment. The court concluded that, because defendant did not plead guilty to a sexual offense, he was required to serve a mandatory parole term. This appeal followed.

I. Timeliness of Motion
As a preliminary matter, we reject the People's assertion that we should not consider the merits of defendant's appeal because the underlying Crim. P. 35(a) motion was untimely filed.
Under Crim. P. 35(a), an illegal sentence may be corrected at any time, while under Crim. P. 35(b), a sentence imposed in an illegal manner must be corrected within the 120-day period provided for the reduction of sentence.
Defendant's motion challenges the legality of his mandatory parole term and not, as the People assert, the manner in which that term was imposed. The motion contends that (1) defendant's conviction is for a sex crime, and (2) the statutes governing parole for sex crimes committed in 1993 authorize only a discretionary parole period. This contention amounts to an allegation that the mandatory parole portion of defendant's sentence is illegal. See People v. Green, 36 P.3d 125 (Colo.App.2001)(an illegal sentence is one that is inconsistent with the penalty prescribed by statute).
Defendant's motion was timely under Crim. P. 35(a), and we consider his appeal on the merits.


*902 II. Mandatory vs. Discretionary Parole
Defendant contends that the parole portion of his sentence is illegal because he was effectively sentenced for a conviction of an offense with a factual basis involving unlawful sexual behavior and, therefore, he was subject to a discretionary parole period under § 17-2-201(5)(a), C.R.S.2003, rather than the mandatory parole period provided in § 18-1.3-401(1)(a)(V)(A). We agree.
Section 17-2-201(5)(a) applies to offenders who are convicted of certain crimes committed before July 1, 1996. See Martin v. People, 27 P.3d 846 (Colo.2001). Subsection (5)(a) states that "as to any person sentenced for conviction of an offense involving unlawful sexual behavior or for which the factual basis involved an offense involving unlawful sexual behavior, as defined in section 16-22-102(9), C.R.S. [2003] ... the [state parole] board has the sole power to grant or refuse to grant parole."
The resolution of this issue requires us to interpret the term "factual basis" for purposes of § 17-2-201(5)(a). As an initial matter, we note that § 17-2-201(5)(a.5), C.R.S.2003, is substantially similar to subsection (5)(a) in all relevant respects, but applies to crimes committed on or after July 1, 1996 and prior to July 1, 2002. Cf. § 17-2-201(5)(a.6), C.R.S.2003 (for offenses committed on or after July 1, 2002, involving unlawful sexual behavior or having an underlying factual basis involving unlawful sexual behavior, a defendant is subject to mandatory parole as set forth in § 18-1.3-401(1)(a)(V)(A), unless that defendant is subject to the Colorado Sex Offender Lifetime Registration Act of 1998, § 18-1.3-1001, et seq., C.R.S.2003).
When interpreting a statute, we attempt to implement the intent of the General Assembly. To discern that intent, we look first to the plain language of the statute and interpret statutory terms in accordance with their commonly accepted meanings. People v. Terry, 791 P.2d 374, 376 (Colo.1990).
In People v. Pahlavan, 83 P.3d 1138, 2003 WL 1923030 (Colo.App. No. 01CA1331, Apr. 24, 2003), a division of this court concluded that the language "offense ... for which the factual basis involved an offense involving unlawful sexual behavior" of § 17-2-201(5)(a.5) includes offenses other than the sex offenses enumerated in § 16-22-102(9). Thus, in Pahlavan, the division concluded that § 17-2-201(5)(a.5) applied to a defendant convicted of kidnapping where the jury found, by special interrogatory, that the kidnapping included a sexual assault. The division thus determined that the special interrogatory finding was a "factual basis" involving unlawful sexual behavior, and therefore, the defendant was required to serve a period of discretionary parole.
Unlike in Pahlavan, here, there is no express factual finding on which to base a determination of whether defendant's offense involved unlawful sexual behavior. Therefore, we look to other related statutes to determine the meaning of "factual basis." See § 2-4-203(1)(d), C.R.S.2003; People v. Sorrendino, 37 P.3d 501, 503 (Colo.App.2001).
Section 16-7-207(2)(f), C.R.S.2003, and Crim. P. 11 prescribe that a trial court shall not accept a guilty plea without first determining there is a factual basis for the plea.
The supreme court has held that for purposes of § 16-7-207(2)(f) and Crim. P. 11, the factual basis is established from the record as a whole. See Wilson v. People, 708 P.2d 792, 798 (Colo.1985). The supreme court further instructed in People v. Fleming, 781 P.2d 1384 (Colo.1989), that the factual basis for a guilty plea may be established by three methods: (1) inquiring of the defendant; (2) inquiring of the prosecutor; and (3) examining the presentence report.
Similarly, in People v. McMurrey, 39 P.3d 1221 (Colo.App.2001), a division of this court held that, pursuant to §§ 16-11.7-102 to -106, C.R.S.2003, the Department of Corrections (DOC) has statutory authority to classify a defendant not convicted of a sex offense as a sex offender for purposes of treatment. Section 16-11.7-102(2)(a), C.R.S.2003, defines "sex offender" to include those convicted on or after July 1, 2000, "of any criminal offense, the underlying factual basis of which involves a sex offense." The DOC regulations classify "sex offenders" to include individuals whose plea agreements involve the factual basis of a *903 crime involving a sex offense. DOC Admin. Reg. 700-19, art. IV(A) (2003). The DOC regulations also provide: "The factual basis is determined from the Pre-Sentence Investigation Report, law enforcement records and/or court transcripts." DOC Admin. Reg. 700-19, art. IV(E) (2003).
Here, a presentence report, which was provided to the trial court and made part of the record, contained a description of defendant's sexual assault and his own admissions regarding the assault. The underlying circumstances of defendant's original charge of second degree burglary committed with the intent to commit third degree sexual assault were made part of the record and considered by the trial court in sentencing him. Under § 16-22-102(9), third degree sexual assault, in violation of § 18-3-404 as it existed before July 1, 2000, is classified as unlawful sexual behavior.
Further, although defendant pleaded guilty to an amended charge, which stated that he unlawfully entered a dwelling with the intent to commit therein the crime of harassment, he was repeatedly ordered to undergo sex offender treatment.
Additionally, a broad interpretation of "factual basis" is consistent with the legislative intent that the parole board have discretion to determine the length of parole terms for sex offenders. See Martin v. People, supra, 27 P.3d at 849-51; see also People v. Meidinger, 987 P.2d 937 (Colo.App.1999)(defendant was determined to be a sex offender because she had a "history of sex offenses" pursuant to § 16-11.7-102(2), even though she had pleaded guilty to an offense that was not an enumerated sex offense).
We note that in People v. Cooper, 27 P.3d 348 (Colo.2001), the supreme court interpreted § 17-2-201(5)(a.5) to apply to persons convicted of sexual offenses and to control over more general sentencing statutes.
Pursuant to § 17-2-201(5)(a) and (a.5), a trial court must determine, based on the statements by the defendant, statements by the prosecutor, and the presentence report, whether the defendant has been convicted of an offense for which the factual basis involved an offense involving unlawful sexual behavior, as defined in § 16-22-102(9). Based on this determination, the court must then determine whether to sentence the defendant to mandatory or discretionary parole. Although there is some evidence in defendant's presentence report supporting a finding of a factual basis for an offense involving unlawful sexual behavior, we nevertheless remand to the trial court to make this factual determination after considering the parties' positions and the record as a whole.
Accordingly, the order is vacated as to the imposition of mandatory parole, and the case is remanded to the trial court to determine whether defendant was sentenced for an offense for which the factual basis involved an offense involving unlawful sexual behavior and to impose a sentence in accordance with the views expressed in this opinion and consistent with § 17-2-201(5)(a).
In its petition for rehearing, the People argue that our opinion renders § 17-2-201(5)(a) unconstitutional under Apprendi v. New Jersey, 530 U.S. 466, 120 S.Ct. 2348, 147 L.Ed.2d 435 (2000), because it requires the district court to make an independent factual finding that may increase defendant's sentence. In Apprendi, the Supreme Court stated: "Other than the fact of a prior conviction, any fact that increases the penalty for a crime beyond the prescribed statutory maximum must be submitted to a jury, and proved beyond a reasonable doubt." Apprendi v. New Jersey, supra, 530 U.S. at 490, 120 S.Ct. at 2362-63, 147 L.Ed.2d at 455.
In his response to the petition for rehearing submitted at our request, defendant maintains that Apprendi has no application to this case.
Apprendi protects the constitutional rights of defendants in criminal cases. Here, we conclude that defendant's assertion that Apprendi does not apply constitutes a waiver of any argument defendant might have that our remand violates his constitutional rights as protected in that case. We conclude further that defendant's waiver applies to factual determinations the trial court makes on remand regarding whether defendant was sentenced for an offense for which the factual basis involved an offense involving unlawful sexual behavior.
*904 We express no opinion whether such factual determination by the trial court would violate the rule in Apprendi.
Judge NIETO and Judge CARPARELLI concur.
