
176 Cal.App.4th 1493 (2009)
In re R.O., a Person Coming Under the Juvenile Court Law.
THE PEOPLE, Plaintiff and Respondent,
v.
R.O., Defendant and Appellant.
No. B208117.
Court of Appeals of California, Second District, Division One.
August 25, 2009.
CERTIFIED FOR PARTIAL PUBLICATION[*]
*1495 Laini Millar Melnick, under appointment by the Court of Appeal, for Defendant and Appellant.
Edmund G. Brown, Jr., Attorney General, Dane R. Gillette, Chief Assistant Attorney General, Pamela C. Hamanaka, Assistant Attorney General, James William Bilderback II and Marc A. Kohm, Deputy Attorneys General, for Plaintiff and Respondent.

OPINION
ROTHSCHILD, J. 
This case raises the question whether the juvenile court has discretion to set a lesser term of confinement than the indeterminate sentence applicable to an adult convicted of the same offense as the juvenile. We conclude that the juvenile court has discretion to set a lesser maximum term of confinement "based upon the facts and circumstances of the matter." Therefore, we will remand the case to the court to exercise that discretion. In all other respects, the court's orders are affirmed.

FACTS AND PROCEEDINGS BELOW
The Compton Varios 70s (CV70's) and the Compton Varios Segundos (CVS) are rival gangs. The boundary between their territories is Compton Boulevard. On an evening in October 2007 Danny Rodriguez, a member of the CV70's, was shot and killed near the intersection of Compton Boulevard and Williams Avenue. The sheriff's deputies who arrived at the scene a few minutes after the shooting interviewed several bystanders. One witness stated that the shooter ran south on Williams immediately after the shooting, but none of the people interviewed identified the shooter.
Nestor Morales, who was among the persons interviewed at the crime scene, told the interviewing officer that he was working at a taco stand on the corner of Compton and Williams when the shooting occurred. He heard *1496 gunshots and ducked for cover but "didn't see anything." The officer who interviewed Morales testified that he only spoke to Morales for a short time and that Morales was trembling and appeared frightened and disoriented.
Eleven days after the shooting, Deputy Shannon Laren met with Morales. Laren showed Morales a photo "six-pack" and Morales immediately identified R.O. as the shooter. He did not hesitate in his identification of R.O. and he did not identify any other person before or after identifying R.O. At trial Morales identified R.O. as the shooter. He also testified that he recognized R.O. as a customer of his taco stand.
Undisputed evidence showed that R.O. lived two blocks from the intersection of Compton and Williams and that the shortest route from the murder scene to R.O.'s house was south on Williams, the direction in which the shooter ran. R.O.'s brother testified that R.O. was at home just before the shooting. A sheriff's gang expert testified that R.O. was an "associate" of the CVS gang.
The juvenile court sustained the allegations of a petition charging R.O. with first degree murder and the use of a firearm in the commission of the crime. The court rejected the allegation that R.O. committed the murder for the benefit of a criminal street gang. The court ordered R.O. committed to California's Department of Corrections and Rehabilitation, Division of Juvenile Facilities for a period not to exceed 35 years to life, which the court believed was the mandatory sentence for an adult convicted of the same offense with a finding of true on the same enhancement. (Pen. Code, §§ 190, subd. (a), 12022.53, subd. (b).)[1]
On appeal, R.O. maintains that the testimony of Morales, the prosecution's only witness to the murder, was insufficient to sustain the petition and that the court erred in committing him to the Division of Juvenile Facilities and in failing to exercise its discretion in setting his maximum confinement period.
We conclude that the evidence was sufficient to sustain the petition and the court did not abuse its discretion in committing R.O. to the Division of Juvenile Facilities. We conclude, however, that the court erred in failing to exercise its discretion in setting the maximum term of confinement and we remand the matter to the juvenile court for reconsideration consistent with this opinion.


*1497 DISCUSSION

I., II.[*]

III. The Juvenile Court's Discretion to Set a Maximum Period of Confinement "Based Upon the Facts and Circumstances of the Matter."

After finding that R.O. committed a first degree murder in which he personally used a firearm, the court concluded that it had no choice but to set a maximum term of confinement equal to the mandatory sentence applicable to an adult convicted of the same offense.[3] R.O. argues that the court erred in concluding that it lacked discretion to impose a lesser period of confinement. We agree.
Prior to January 2004, Welfare and Institutions Code section 731[4] stated in relevant part: "A minor committed to the Department of the Youth Authority may not be held in physical confinement for a period of time in excess of the maximum period of imprisonment which could be imposed upon an adult convicted of the offense or offenses which brought or continued the minor under the jurisdiction of the juvenile court." (Italics added.)
Effective January 2004, the Legislature amended section 731, subdivision (b) (now subd. (c)), to read as follows: "A minor committed to the Department of the Youth Authority also may not be held in physical confinement for a period of time in excess of the maximum term of physical confinement set by the court based upon the facts and circumstances of the matter or matters which brought or continued the minor under the jurisdiction of the juvenile court, which may not exceed the maximum period of adult confinement as determined pursuant to this section."[5] (Italics added.) (Sen. Bill No. 459 (2003-2004 Reg. Sess.) § 1, enacted as Stats. 2003, ch. 4, § 1.)
(1) The authority to consider the "facts and circumstances of the matter" necessarily implies the authority to impose a term shorter than the term *1498 applicable to an adult for the same crime.[6] Therefore, the court erred when it concluded that it lacked discretion to impose a term of confinement less than the indeterminate term that would have been imposed on an adult convicted of the same offenses.
The Attorney General, however, argues that section 731 not only sets a ceiling on the court's choice of a juvenile's period of confinement, it also sets a floor. Relying on In re Joseph M. (2007) 150 Cal.App.4th 889 [58 Cal.Rptr.3d 756] (Joseph M.), the Attorney General reasons that because an adult convicted of first degree murder with the use of a firearm would be subject to a mandatory indeterminate sentence, it follows that the minimum confinement term for R.O. must be the same, there being no low, middle or upper term that the court could select. This result, the Attorney General contends, is consistent with the Legislature's goal in amending section 731 to insure that juveniles and adults serve comparable terms. He also argues that his interpretation of section 731 would avoid the "potentially bizarre result" of a minor who committed murder being confined for a shorter period than a minor who committed a less serious crime.
We reject the Attorney General's interpretation because the plain language of section 731, subdivision (c), which requires the court to consider the "facts and circumstances of the matter," explicitly vests in the court discretion to select a period of confinement that is less than the minimum mandatory indeterminate sentence.
The Attorney General's reliance on Joseph M. is misplaced. In Joseph M., the court held that if an adult committing the same offense as the minor would be sentenced under the triad structure of the determinate sentencing law, the juvenile court may not order a period of confinement that is less than the lowest term in the triad to which the adult could be sentenced, plus enhancements. (Joseph M., supra, 150 Cal.App.4th at pp. 896-897.) Thus Joseph M. is inapposite because our case involves the interpretation of section 731, subdivision (c) as it affects cases involving indeterminate sentences, not determinate sentences.[7]
*1499 (2) The decision in In re H.D., supra, 174 Cal.App.4th 768, rejected, as we do, the Attorney General's argument that the Legislature intended juvenile offenders and adults to serve comparable sentences. In re H.D. held that the juvenile court, in exercising its discretion under section 731 with respect to an offense carrying a triad sentence was not limited to imposing either the upper, middle or lower term, as would be the case in sentencing an adult, but could select a term in between the three. (174 Cal.App.4th at p. 776.) The court reasoned that "absent some legislative direction" "the wholesale importation of the [determinate sentencing law's] triadic sentencing scheme into the juvenile court law would be inconsistent with [the juvenile law's] sentencing structure...." (Ibid.) The amendment to section 731, subdivision (c) "contains no such direction," the court concluded. (174 Cal.App.4th at p. 776.) On the contrary, the court held, "the statute ties the court's exercise of discretion to `the facts and circumstances of the matter or matters which brought or continued the ward under the jurisdiction of the juvenile court,' strongly suggesting that the court should endeavor to tailor the disposition to the offender and the offense, rather than attempt to shoehorn the punishment into a one-size-fits-all sentencing scheme." (Id. at pp. 776-777.)
(3) In re Carlos E. (2005) 127 Cal.App.4th 1529 [26 Cal.Rptr.3d 551] further supports our interpretation of section 731. In that case the court stated that "[p]roof the juvenile court's decision is not tied directly to the adult system is found in the language utilized; the juvenile court is to consider the facts and circumstances of the matter, rather than being restricted solely to the aggravating or mitigating circumstance scheme for adults. The juvenile court's determination must be tied to the purposes of the juvenile system, which include the protection of the public as well as the rehabilitation of the minor. (§ 202.) [¶] . . . [¶] ... [T]he juvenile court must determine the maximum period of confinement . . . based on the facts and circumstances, this maximum may not be more than that for a comparable adult, but may be less." (127 Cal.App.4th at p. 1542.)
We recognize that both In re H.D. and In re Carlos E. were cases involving adult determinate sentences rather than an indeterminate sentence as in the case here. We see no reason, however, why the courts' reasoning in those cases should not apply in this case.
Legislative history confirms our conclusion as to the intent of section 731, subdivision (c). As the court in In re Carlos E. recognized, the rationale for the change in section 731 arose out of a concern for the Youthful Offender Parole Board's "`tendency to increase [the] . . . length-of-stay beyond the board's own guidelines, and the board's lack of program expertise.'" (In re Carlos E., supra, 127 Cal.App.4th at p. 1541.) Thus, "[t]he Senate Rules Committee analysis states that current law provides that the maximum period *1500 of imprisonment is the term a similarly situated adult would receive, but this bill `would additionally provide that a "minor committed to the Department of the Youth Authority also may not be held in physical confinement for a period of time in excess of the maximum term of physical confinement set by the court based upon the facts and circumstances of the matter or matters which brought or continued the minor under the jurisdiction of the juvenile court."'" (Ibid., boldface added by Carlos E., quoting Sen. Rules Com., Off. of Sen. Floor Analyses, 3d reading analysis of Sen. Bill No. 459 (2003-2004 Reg. Sess.) as amended Mar. 17, 2003, p. 4.)
Our interpretation of section 731, subdivision (c) is consistent with a 150-year tradition of maintaining two separate and distinct criminal justice systemsone for juveniles and one for adults.[8] Describing California's original juvenile justice legislation, our Supreme Court observed: "The purpose in view is not punishment for offenses done, but reformation and training of the child to habits of industry, with a view to his future usefulness when he shall have been reclaimed to society, or shall have attained his majority." (Ex Parte Ah Peen (1876) 51 Cal. 280, 281.) Today those same principles are embodied in section 202 which states that the purpose of the juvenile justice system is "(1) to serve the `best interests' of the delinquent ward by providing care, treatment, and guidance to rehabilitate the ward and `enable him or her to be a law-abiding and productive member of his or her family and community,' and (2) to `provide for the protection and safety of the public. . . .'(§ 202, subds. (a), (b) & (d); [citations].)" (In re Charles G. (2004) 115 Cal.App.4th 608, 614-615 [9 Cal.Rptr.3d 503].)
Finally, we disagree with the Attorney General's argument that our interpretation of section 731 will lead to the "potentially bizarre result" of terms of confinement in which teenage murderers will serve less time in confinement than juveniles who commit less serious crimes. We have no reason to believe that in setting the maximum period of confinement for a murderer or a joyrider the juvenile courts will not set appropriate terms based on the facts and circumstances of each case. Nor by this opinion do we intend to suggest how the juvenile court should exercise its discretion in this case. We only hold that pursuant to section 731 the juvenile court must exercise its discretion based on the "facts and circumstances of the matter."

DISPOSITION
The cause is remanded to the juvenile court with directions to vacate its order setting R.O.'s maximum term of confinement and to enter a new order *1501 based on its exercise of discretion pursuant to section 731, subdivision (c), and in conformity with the views expressed in this opinion. In all other respects the court's orders are affirmed.
Mallano, P. J., and Chaney, J., concurred.
NOTES
[*]  Pursuant to California Rules of Court, rules 8.1100 and 8.1110, this opinion is certified for publication with the exception of parts I. and II.
[1]  The court found that R.O. personally and intentionally discharged a firearm causing death to a person other than an accomplice which carries a mandatory consecutive enhancement of 25 years. (Pen. Code, § 12022.53, subd. (d).) The court mistakenly believed that the term was 10 years and thus imposed a maximum 35-year period of confinement.
[*]  See footnote, ante, page 1493.
[3]  See footnote 1, ante. This sentence, of course, is a theoretical maximum period of confinement. Absent unusual circumstances R.O. cannot be confined beyond his 25th birthday. (Welf. & Inst. Code, § 1771.) See discussion in footnote 6, post.
[4]  All future statutory references are to the Welfare and Institutions Code.
[5]  A subsequent amendment designated this subdivision as subdivision (c) and, to avoid confusion, we will refer to it as subdivision (c) in the future. Subsequent amendments also changed the term minor to ward and renamed the Youth Authority the Division of Juvenile Facilities. None of these changes affect our analysis of the statute.
[6]  The juvenile court's discretion to set the minor's theoretical maximum period of confinement does not alter the Youth Authority Board's authority to discharge the minor "as soon as in its opinion there is reasonable probability that he or she can be given full liberty without danger to the public." (§ 1765, subd. (b).) In most cases, a minor committed for perpetrating a felony "shall be discharged when such person reaches his 25th birthday." (§ 1771.) And, as a general rule, a minor confined for committing first degree murder is eligible for parole consideration at least every seven years. (Cal. Code Regs., tit. 15, § 4951.)
[7]  This case does not require us to decide whether we agree with the holding in Joseph M. that the court's discretion in triad cases is limited to imposing the lowest term. (Cf. In re H.D. (2009) 174 Cal.App.4th 768 [94 Cal.Rptr.3d 627], discussed below.)
[8]  California's initial juvenile delinquency legislation, the Industrial School Act, was adopted in 1858. (Stats. 1858, ch. 209, p. 166; see Macallair, The San Francisco Industrial School and the Origins of Juvenile Justice in California: A Glance at the Great Reformation (2003) 7 U.C. Davis J. Juv. L. & Pol'y 1.)
