
184 P.3d 349 (2008)
2008 MT 168
In the Matter of D.A.S., a Youth.
No. DA 06-0849.
Supreme Court of Montana.
Submitted on Briefs February 20, 2008.
Decided May 13, 2008.
*350 For Appellant: Stephen H. Dalby, Attorney at Law; Libby, Montana.
For Appellee: Hon. Mike McGrath, Attorney General; Mark Mattioli, Assistant Attorney General, Helena, Montana Bernard G. Cassidy, Lincoln County Attorney; Libby, Montana.
Justice JIM RICE delivered the Opinion of the Court.
¶ 1 D.A.S. appeals the conditions of his probation imposed by the District Court of the Nineteenth Judicial District, Lincoln County. We affirm.
¶ 2 We consider the following issue on appeal:
¶ 3 Did the District Court impose illegal conditions on D.A.S.'s sentence for his adjudication as a delinquent youth and serious youth offender?

FACTUAL AND PROCEDURAL BACKGROUND
¶ 4 In June 2003, a petition was filed alleging that fourteen-year-old D.A.S. was a delinquent youth because he had committed two counts of sexual assault, felonies, in violation *351 of § 45-5-502(3), MCA. D.A.S. admitted one count and denied the second. In October 2003, based on D.A.S.'s admission, the District Court declared D.A.S. a delinquent youth and a serious juvenile offender as defined in § 41-5-103, MCA. The court committed D.A.S. to the Department of Corrections until age eighteen or until an earlier discharge. D.A.S. was placed in the sex offender unit at Pine Hills Youth Correctional Facility (Pine Hills) and ordered to successfully complete sex offender treatment. While at Pine Hills, D.A.S. committed two additional sexual offenses, resulting in his placement in an "intensive supervision program." D.A.S. did not successfully complete sex offender treatment during his stay at Pine Hills.
¶ 5 Shortly before D.A.S. reached the age of majority in 2006, the state filed a motion to transfer jurisdiction and supervisory responsibility from the youth court to the District Court, and to impose conditions, pursuant to § 41-5-208, M.C.A.D.A.S. waived his right to a transfer hearing, stipulated to transfer of jurisdiction to the District Court and to adult supervision, and agreed to be classified as a "level 1 offender." Thereafter, a hearing was conducted to determine supervisory conditions. D.A.S. objected to several proposed conditions on the basis that they were either inapplicable or unrelated to the charged offense. Probation Officer George Clough (Clough) testified in support of the conditions. In its Order of Disposition, the District Court imposed eighteen conditions on D.A.S.'s probation. Pertinent to this appeal are conditions 7, 9, 10, and 12, which provide:
7. The Youth shall not possess or use illegal drugs or any drugs unless prescribed by a licensed physician. The Youth shall not be in control of or under the influence of illegal drugs, nor shall he have in his possession any drug paraphernalia.
. . . .
9. The Youth shall not possess or consume intoxicants/alcohol, nor shall he enter any place intoxicants are the chief item of sale. Defendant shall submit to Breathalyzer testing or bodily fluid testing for drugs or alcohol as requested by his Probation/Parole Officer.
10. The Youth shall abide by a curfew as determined necessary and appropriate by his Probation/Parole Officer.
. . . .
12. The Youth shall obtain his GED one (1) year prior to sentence expiration.
¶ 6 Prior to imposing the conditions of probation the District Court addressed D.A.S.:
[D.A.S.], I want you to understand something. I am not imposing conditions here to give you a bunch of problems to make it easier for you to fail. I'm trying to give you the tools to make it possible for you to succeed. I don't think I can just put you on probation and give you one or two conditions because I think that will cause you to fail. Mr. Clough needs to have some reasonable restrictions that he can hold you to, to make sure that you are doing what you need to do. . . .
I am hoping that you can get in with a therapist, that you can make progress, that you can complete treatment, and that you can be discharged early from this sentence. I don't want to have this hanging over you for the next seven years. And I hope that is what you want also.
¶ 7 The District Court placed D.A.S. on probation until age twenty-five, or September 11, 2013, with the right to petition for early discharge any time after October 30, 2008. D.A.S. challenges the imposition of probationary conditions 7, 9, 10, and 12. Additional facts are discussed as needed below.

STANDARD OF REVIEW
¶ 8 We review challenges to probationary conditions for both legality and abuse of discretion. State v. Ashby, 2008 MT 83, ¶ 9, 342 Mont. 187, ¶ 9, 179 P.3d 1164, ¶ 9. The sentencing statutes allow a district court to impose conditions of probation that are "reasonable restrictions" necessary to rehabilitate the offender or protect the victim and society. Ashby, ¶ 9 (citing § 46-18-201(4)(n), MCA (2005)). Accordingly, we first review a condition of probation for legality and then *352 review the condition for an abuse of discretion. Ashby, ¶ 9.

DISCUSSION
¶ 9 Did the District Court impose illegal conditions on D.A.S.'s sentence for his adjudication as a delinquent youth and a serious youth offender?
¶ 10 D.A.S. contends that there exists "no logical connection between the conditions of probation numbered 7, 9, 10, and 12 and the crime for which [D.A.S.] was convicted." D.A.S. relies on our decision in State v. Ommundson, 1999 MT 16, ¶ 12, 293 Mont. 133, ¶ 12, 974 P.2d 620, ¶ 12, to argue that a sufficient "nexus" between the conditions and the charged offense does not exist, making the conditions of probation illegal. However, we recently expanded the Ommundson holding in Ashby. There we determined that "a sentencing judge may impose a particular condition of probation so long as the condition has a nexus to either the offense for which the offender is being sentenced, or to the offender himself or herself." Ashby, ¶ 15.
¶ 11 We note further that this case involves a youth offender who was sentenced pursuant to the Montana Youth Court Act, § § 41-5-101 et seq., MCA. The Act delineates "express legislative purposes," including a system which provides "a program of supervision, care, rehabilitation, detention, competency development, and community protection for youth before they become adult offenders[.]" Section 41-5-102(2)(b), MCA. We thus turn to the challenged conditions.
Conditions 7 and 9: Drug and Alcohol Prohibition
¶ 12 D.A.S. contends that there is "no documented connection in this case between [his] criminal conduct and the use or possession of illegal drugs or drug paraphernalia" and there is "no evidence that [he] was intoxicated when he perpetrated the assault[,]" thus rendering Conditions 7 and 9 invalid. However, the record reveals that prior to his offense D.A.S. was immersed in an illegal drug environment, with his family actively engaging in illegal drug use. In fact, D.A.S. explained that his "trigger" for sexually offending "was not being allowed into his parents' bedroom with his sisters and younger nephew . . . while they were doing drugs." Further, Clough testified that clients of a sexual offender treatment program must refrain from alcohol use, and thus a prohibition on alcohol is consistent with placement of D.A.S. within a sexual offender program and the need for him to successfully complete the program. While alcohol or drugs were not present during the commission of D.A.S.'s crime, both prohibitions are reasonably related to D.A.S. and his individual rehabilitation, as permitted pursuant to the Ashby rule, and imposition of the conditions were not an abuse of discretion.
Condition 10: Curfew
¶ 13 Similarly, D.A.S. contends that Condition 10 is illegal because "there is no evidence in the transcript that abiding by a curfew is in any way related to the crime for which [he] was convicted." D.A.S. committed his first offense at age fourteen and his childhood was fraught with environmental instability. The record reveals that prior to his commitment at Pine Hills, D.A.S. was living in a van with his mother and stepfather, did not regularly attend public school, and failed to attend counseling. Moreover, while at Pine Hills, D.A.S. committed two additional sexual offenses that resulted in his placement in an intensive supervision program to provide additional supervision. Consistent with the legislative intent of providing youth offenders with "a program of supervision," § 41-5-102(2)(b), MCA, Condition 10 allows D.A.S.'s probation officer to establish a curfew if one is needed to ensure that D.A.S. develops a consistent and healthy routine, which as Clough testified was appropriate for youth offenders. Thus, a curfew is reasonable given D.A.S.'s circumstances and the legislative intent of providing youth offenders with additional supervision, and imposition of Condition 10 was not an abuse of discretion.
Condition 12: Completion of GED
¶ 14 Lastly, D.A.S. contends that Condition 12 is illegal because there is no *353 "connection between the crime and the lack of a GED[.]" The record reveals D.A.S. did not regularly attend public school. At the sentencing hearing, D.A.S. indicated that he had previously studied for and taken a GED exam while he was at Pine Hills and was surprised when he had not passed the test, but that he still wanted to obtain his GED. When asked by the District Court whether he was interested in "going back and refreshing [his] studying and taking the test again," D.A.S. replied "I'd like to, yeah." D.A.S. had further expressed an interest in attending college. Clough testified that a GED requirement would allow youthful offenders to "leave probation a little bit better off than [they started], in hopes of maybe being able to get a little bit better job and that sort of thing." The District Court thus imposed the GED condition, stating it was "for [D.A.S.'s] own good, just to keep [him] focused. . . ."
¶ 15 These circumstances demonstrate that the GED condition was appropriately imposed. Deprived of educational opportunities by his family's lack of proper care, D.A.S. was apparently close to obtaining his GED and expressed a desire to finish studying and take the exam again. The testimony indicates the potential benefit of a GED to a youthful offender. Further, the GED requirement is consistent with the legislative purpose of rehabilitating youth offenders through "competency development," in an effort to ensure that the youth offender does not become an adult offender. Section 41-5-102(2)(b), MCA. The District Court carefully considered the many issues in D.A.S.'s life and sought to provide a program for his supervision, improvement, and early discharge. A GED will help D.A.S. prepare for future opportunities critical in his effort to avoid re-offending. We thus conclude that the GED requirement was appropriate and was not an abuse of the District Court's discretion.
¶ 16 Affirmed.
We concur: W. WILLIAM LEAPHART, PATRICIA COTTER, JAMES C. NELSON and JOHN WARNER, JJ.
