
104 Cal.Rptr.2d 868 (2001)
87 Cal.App.4th 912
ROBERT L., Petitioner,
v.
The SUPERIOR COURT of Orange County, Respondent;
The People, Real Party in Interest.
No. G027381.
Court of Appeal, Fourth District, Division Three.
March 8, 2001.
Review Granted October 24, 2001.
*869 Carl C. Holmes, Public Defender, Deborah Kwast, Chief Deputy Public Defender, and Kevin J. Phillips, Assistant Public Defender, for Petitioner.
No appearance, for Respondent.
Tony Rackauckas, District Attorney and Brian N. Gurwitz, Deputy District Attorney, for Real Party in Interest.

OPINION
BEDSWORTH, J.
In this case, we interpret a recent amendment to the Street Terrorism Enforcement and Prevention Act (Pen.Code, § 186.20 et seq.) that was accomplished by the passage of Proposition 21. Particularly, we endeavor to ascertain the nature and scope of newly-enacted Penal Code section 186.22, subdivision (d). That provision describes criminal penalties for any person who is convicted of an offense punishable as a felony or a misdemeanor, which is committed for the benefit of, and with the specific intent to promote, a criminal street gang. Petitioner Robert L. contends the provision sets forth a penalty scheme that applies only to so-called wobbler offenses. Real party in interest, represented by the district attorney, maintains the provision constitutes a substantive offense that applies to both felonies and misdemeanors. The parties are both partly right. We hold the scope of the provision includes all gang-related offenses, not just wobblers. We also find the statute is more aptly characterized as a penalty provision than a crime. Because the prosecution in this case charged the provision as a substantive offense, we grant petitioner's request for a writ of mandate compelling respondent court to sustain his demurrer to that charge with leave to amend. We deny the petition for a writ of prohibition preventing respondent court from taking further action against petitioner in this case.

* * *
On May 16, 2000, the Orange County District Attorney filed an amended petition alleging petitioner came within the jurisdiction of the juvenile court. (Welf. & Inst.Code, § 602.) Count 1 charged petitioner *870 with simple battery, and count 2 charged him with street terrorism. (See Pen.Code, §§ 242, 186.22, subd. (a).)[1] Both counts were designated felonies. The petition also alleged that the battery was committed for the benefit of, and with the specific intent to promote, a criminal street gang within the meaning of section 186.22, subdivision (d) (hereafter section 186.22(d)).
Petitioner demurred on the grounds that count 1 alleged a crime, i.e., felony battery, that does not exist. The same day, the district attorney filed a second amended petition moving count 1 to count 3 and relabeling it as a misdemeanor. In addition, the gang allegation was converted to a substantive offense in a new count 1. That count reads, "On or about April 1, 2000, [petitioner], in violation of Section 188.22(d) ... (CRIMINAL STREET GANG FELONY), a FELONY, having the specific intent to promote, further, and assist in criminal conduct by members of BAKER STREET, a criminal street gang, did willfully and unlawfully commit the public offense of BATTERY, in violation of ... section 242, for the benefit and at the direction of, and in association with BAER STREET."
Petitioner again demurred, claiming that new count 1 failed to state a valid offense. The trial court overruled the demurrer, prompting petitioner to seek extraordinary relief in this court. We issued an order to show cause for a writ of mandate/prohibition and stayed further proceedings in the lower court.

I
Petitioner contends section 186.22(d) does not apply to crimes such as battery, which are punishable only as misdemeanors.[2] We find no such limitation in the law.
Section 186.22(d) provides, "Any person who is convicted of a public offense punishable as a felony or a misdemeanor, which is committed for the benefit of, at the direction of or in association with, any criminal street gang with the specific intent to promote, further, or assist in any criminal conduct by gang members, shall be punished by imprisonment in the county jail not to exceed one year, or by imprisonment in the state prison for one, two, or three years, provided that any person sentenced to imprisonment in the county jail shall be imprisoned for a period not to exceed one year, but not less than 180 days, and shall not be eligible for release upon completion of sentence, parole, or any other basis, until he or she has served 180 days. If the court grants probation or suspends the execution of sentence imposed upon the defendant, it shall require as a condition thereof that the defendant serve 180 days in county jail."
At issue is the first clause of the statute. Petitioner reads it to mean the statute comes into play only when a person is convicted of a public offense which is punishable in the alternative as a felony or a misdemeanor. This category of offenses, commonly called "wobblers" (see People v. Robles (2000) 23 Cal.4th 1106, 1113, 99 Cal.Rptr.2d 120, 5 P.3d 176), does not include battery. (See ante, fn. 2.) Real party in interest, on the other hand, interprets the scope of the statute to include any person who is convicted of a crime punishable as a felony or any person who is convicted of a crime punishable as a misdemeanor.
In construing section 186.22(d), we rely on well-established rules of statutory construction. "When, as in this case, a statute is ambiguous, we typically consider evidence of the Legislature's intent beyond the words of the statute. The court *871 may examine a variety of extrinsic aids, including the statutory scheme of which the provision is a part, the history and background of the statute, the apparent purpose, and any considerations of constitutionality, `in an attempt to ascertain the most reasonable interpretation of the measure.' [Citations.]" (Hughes v. Board of Architectural Examiners (1998) 17 Cal.4th 763, 776, 72 Cal.Rptr.2d 624, 952 P.2d 641.) The same rules apply in interpreting a voter initiative (People v. Rizo (2000) 22 Cal.4th 681, 685, 94 Cal.Rptr.2d 375, 996 P.2d 27), with the focus of our inquiry being "the electorate's purpose, as indicated in the ballot arguments and elsewhere." (Hodges v. Superior Court (1999) 21 Cal.4th 109, 114, 86 Cal.Rptr.2d 884, 980 P.2d 433.)
Section 186.22(d) was enacted as part of Proposition 21, which was approved by the voters and became effective in March 2000. A wide-ranging measure, Proposition 21 "made numerous changes to the Penal Code and Welfare and Institutions Code relating to the adult and juvenile justice systems, including the treatment of juvenile offenders, the confidentiality protections afforded to juvenile proceedings, the type of juvenile offenders that can be tried in adult court, and the punishment for gang-related offenses and offenders." (In re Melvin J. (2000) 81 Cal.App.4th 742, 744, 96 Cal.Rptr.2d 917 [interpreting Proposition 21's amendments to Welfare and Institutions Code section 777].)
These changes were designed to combat violent crime committed by juveniles and gang members. (Prop.21, § 2.) As explained in the "Findings and Declarations" section of Proposition 21, "Criminal street gangs and gang-related violence pose a significant threat to public safety and the health of many of our communities. Criminal street gangs have become more violent, bolder, and better organized in recent years." (Prop.21, § 2, subd. (b).) Despite "a substantia] and consistent four year decline in overall crime ... [v]iolent juvenile crime has proven most resistant to this positive trend." (Prop.21, § 2, subd. (c).)
To address this problem, Proposition 21 calls for severe penalties for gang-related felonies. (Prop.21, § 2, subd. (h).) In fact, this was one of the major selling points of the measure. Its backers promised Proposition 21 would end "the `slap on the wrist' of current law by imposing real consequences for GANG MEMBERS, RAPISTS AND MURDERERS who cannot be reached through prevention or education." (Ballot Pamp., Primary Elec. (March 7, 2000) argument in favor of Prop. 21, p. 48.) It was promised that this would "send a clear message that violent juvenile criminals will be held accountable for their actions and that the punishment will fit the crime." (Ibid.)
That message will be lost if section 186.22(d) is construed as applying only to wobblers, because the punishment provided in that section is actually more lenient than is provided for many a wobbler. Take, for example, the ail-too common wobbler of assault with a deadly weapon. Under normal circumstances, that offense is punishable by up to four years in prison. (§ 245, subd. (a)(1).) However, if a person committed the crime to benefit, and with the specific intent to promote, a criminal street gang, the stiffest sentence he could receive under section 186.22(d) would be three years in prison. Clearly, the electorate did not intend to reduce the penalty for gang-related gun assaults when it approved Proposition 21. Yet, that would be one of the side effects of limiting section 186.22(d) to wobblers.
Petitioner downplays this consequence, contending it pales in comparison to other evils that will arise if the scope of section 186.22(d) is interpreted more broadly as applying to both misdemeanors and felonies. Noting that a violation of section 186.22(d) is punishable in the court's discretion as a misdemeanor, petitioner correctly points out that an offender who commits a serious gang-related crime could be sentenced to less than a year in *872 jail under the statute. However, that could only happen if the prosecution chose to pursue a conviction under section 186.22(d) in the first place. Nothing in Proposition 21 compels the prosecution to so choose when other charging alternatives are available. We presume prosecutors will exercise their charging discretion in a manner that is consistent with the will of the electorate and the goal of achieving substantial justice (see Prop. 21, § 37 [expressing the intent that if another law provides greater punishment, it shall take precedence over the provisions of Proposition 21] ) or the electorate will render them private practitioners. The mere possibility that in some instances prosecutors could use section 186.22(d) to frustrate the purpose of Proposition 21 is insufficient justification for adopting petitioner's construction of the statute, which would allow random chance to defeat the Proposition's design. (See In re Executive Life Ins. Co. (1995) 32 Cal.App.4th 344, 373, 38 Cal. Rptr.2d 453 [courts should not be overly sensitive to the possibility that a particular interpretation of a statute may lead to unintended consequences because the universe of such consequences "approaches the infinite"].)
Petitioner also fears that including misdemeanor offenders within the ambit of section 186.22(d) will lead to overly harsh results in some cases. For instance, if a person is convicted of a minor offense under the circumstances set forth in the statute, he or she could be sentenced to as much as three years in prison and suffer adverse consequences in the future by virtue of the conviction. Petitioner decries this potentiality as being absurd, but he forgets our task is not to judge the wisdom of Proposition 21. (Bramberg v. Jones (1999) 20 Cal.4th 1045, 1048, 86 Cal. Rptr.2d 319, 978 P.2d 1240; People v. Weidert (1985) 39 Cal.3d 836, 846, 218 Cal. Rptr. 57, 705 P.2d 380.) Nor should we be concerned with "whether the drafters, voters or legislators consciously considered all the effects and interrelationships of the provisions they wrote and enacted." (People v. Garcia (1999) 21 Cal.4th 1, 14, 87 Cal.Rptr.2d 114, 980 P.2d 829.) Rather, our goal is simply to interpret Proposition 21 so as to harmonize and give effect to its provisions without doing violence to its language or spirit. (Ibid.)
In order to do that, it is useful to understand the historical underpinnings of the measure. Known as the "Gang Violence and Juvenile Crime Prevention Act of 1998" (Prop.21, § 1), Proposition 21 traces it roots back to former Governor Pete Wilson. In 1998, thenGovernor Wilson sponsored a legislative crime package designed to overhaul the juvenile justice system and crack down on juvenile offenders. (See Governor's Press Release no. 41 (Feb. 3, 1998).) That legislation was defeated, but it was repackaged and put on the ballot as Proposition 21. (See 2000 Propositions (Feb.2000) California Journal, at p. 63; Ballot Pamp., Primary Elec. (March 7, 2000) argument against Prop. 21, p. 49.) By studying the defeated legislation, we can gain valuable insight into how the framers of Proposition 21 intended that initiative to operate. (See generally Horwich v. Superior Court (1999) 21 Cal.4th 272, 283, 87 Cal.Rptr.2d 222, 980 P.2d 927 [recognizing that the drafters of initiatives are presumed to be aware of the existing state of the law and are capable of using language that changes the law].)
The two main bills in Governor Wilson's 1998 crime package were Senate Bill No. 1455 and Assembly Bill No. 1735. Both of these bills proposed to amend section 186.22(d) in the very same manner that Proposition 21 did. (See Sen. Bill No. 1455 (1997 1998 Reg. Sess.) § 4; Assem. Bill No. 1735 (1997-1998 Reg. Sess.) § 4.) The Senate record shows the proposed amendment was designed to "apply to gang members who commit misdemeanors as well as felonies." (Sen. Subcom. on Juvenile Justice, Rep. on Sen. Bill No. 1455 for April 20, 1998, hearing p. 15.) The Assembly record reflects the same. According to an analysis conducted by the *873 Assembly Committee on Public Safety, the amendment was intended to make any gang-related misdemeanor or felony punishable by up to three years in prison. (Assem. Com. on Public Safety, Analysis of Assem. Bill No. 1735, p. 2.) Speaking directly to the issue involved in this case, the committee concluded the amendment "[w]ould allow a person who commits a misdemeanor for the benefit of a criminal street gang to be sent to state prison." (Ibid.)
This was not a novel idea. The Legislature fully recognized that its proposed amendment would effectively restore the "gang-related misdemeanor language" contained in the original version of section 186.22. (Summary of Provisions of the Gang Violence and Juvenile Crime Prevention Act of 1998, prepared for the Sen. and Assem. Corns, on Public Safety, p. 2.) That language, which was set forth in subdivision (b) of the original statute, provided, "Any person who is convicted of a felony or a misdemeanor which is committed for the benefit of, at the direction of, or in association with, any criminal street gang, with the specific intent to promote, further, assist in any criminal conduct by gang members, shall be punished in the following manner...." (Stats.1988, ch. 1242, § 1, p. 4128, italics added.) Although the Legislature did not draw on this exact language when it sought to amend section 186.22(d) in 1998, it is clear what it had in mind. The legislative materials surrounding the proposed amendment seem to us to leave little doubt that the Legislature intended to resurrect the spirit of the original statute and target both gang-related misdemeanors and gang-related felonies.
Nothing in the history of section 186.22 undermines this conclusion. In 1989, the year after section 186.22 was enacted, the Legislature moved the text of subdivision (b) to subdivision (c). (Stats.1989, ch. 144, § 1, p. 1096.) In so doing, the Legislature amended the opening clause of the subdivision from, "Any person who is convicted of a felony or a misdemeanor" to, "Any person who is convicted of a public offense punishable as & felony or a misdemeanor ..." (Ibid., italics added.) On the surface, this would suggest the Legislature intended to change the scope of the statute. But in fact, the amendment was intended to "recast, without substantial change," those provisions relating to the punishment for felony and misdemeanor conduct done with the intent to promote, further, or assist criminal gang activity. (Sen. Rules Com., Office of Sen. Floor Analyses (Sen. Bill No. 1555) May 18, 1989, p. 2.) So we know the amendment did not signal the Legislature's intent to restrict the reach of the statute from gang-related misdemeanors and felonies to simply gang-related wobblers. (See Sen. Com. on Judiciary, Rep. on Sen. Bill No. 1555 for May 16, 1989 hearing p. 1 [describing changes to the statute as "technical amendments"].)
As time passed, the Legislature deleted the text of subdivision (c) altogether. (Stats.1994, ch. 47, § 1.) When Governor Wilson's attempts to resurrect the provision through the Legislature proved unsuccessful, he took the matter directly to the People via Proposition 21. As we have explained, that measure was intended to accomplish what the Legislature was unwilling to do, i.e., restore section 186.22 to its former glory.
In cases involving the interpretation of a voter initiative, it is rare that there will be a legislative blueprint available to help divine the meaning of the measure. However, this is such a case. Given the fact Proposition 21 was derived directly from legislation that failed shortly before its passage, it is entirely reasonable to use that legislation as a guidepost in interpreting section 186.22(d). As shown, there is overwhelming evidence the failed legislation was designed to cover misdemeanors and felonies. We therefore interpret section 186.22(d) as applying to both types of offenses. Because petitioner is alleged to have committed a gang-related misdemeanor, *874 he is subject to the terms of the statute.

II
Petitioner also maintains that rather than defining a crime, section 186.22(d) merely sets forth a penalty provision. With this, we agree.
As our Supreme Court explained in People v. Bright (1996) 12 Cal.4th 652, 49 Cal.Rptr.2d 732, 909 P.2d 1354, "[A] penalty provision prescribes an added penalty to be imposed when the offense is committed under specified circumstances. A; penalty provision is separate from the underlying offense and does not set forth elements of the offense or a greater degree of the offense charged. [Citations.]" (Id. at p. 661, 49 Cal.Rptr.2d 732, 909 P.2d 1354.)
Section 186.22(d) fits this bill. It calls for increased punishment if the underlying offense is committed for the benefit of, and with the specific intent to promote, a criminal street gang. It does not enumerate elements of the underlying offense or divide that offense into degrees. In that sense, section 186.22(d) is closely analogous to other statutes which have been construed as penalty provisions, such as section 664 (People v. Bright, supra, 12 Cal.4th 652, 49 Cal.Rptr.2d 732, 909 P.2d 1354) and section 666 (People v. Bouzas (1991) 53 Cal.3d 467, 279 Cal.Rptr. 847, 807 P.2d 1076).
Real party in interest does not dispute this. However, it maintains that interpreting section 186.22(d) as a penalty provision would preclude the prosecution from utilizing section 186.22, subdivision (b). Like subdivision (d), subdivision (b) applies when the defendant is convicted of a gang-related felony. The only difference is, subdivision (b) is structured as an enhancement so as to provide punishment in addition to the underlying felony.[3] Real party fears that even in cases where the prosecution charges subdivision (b) to the exclusion of subdivision (d), the trial court could still sentence the defendant under the more lenient terms of subdivision (d). Real party's fears are unfounded. While sentencing matters rest within the province of the trial court, the court's sentencing choices are necessarily limited by the prosecutor's initial charging decisions and the factfinder's verdict. (See People v. Superior Court (Alvarez) (1997) 14 Cal.4th 968, 976, 60 Cal.Rptr.2d 93, 928 P.2d 1171; People v. Superior Court (Prudencio) (1927) 202 Cal. 165, 174-175, 259 P. 943, disapproved on other grounds in People v. Superior Court (Howard) (1968) 69 Cal.2d 491, 500-501, 72 Cal.Rptr. 330, 446 P.2d 138.) The court cannot sentence a defendant under a statutory provision that was neither pled nor proved at trial. (See, e.g., People v. Hernandez (1988) 46 Cal.3d 194, 249 Cal.Rptr. 850, 757 P.2d 1013, disapproved on other grounds in People v. King (1993) 5 Cal.4th 59, 78, fn. 5, 19 Cal. Rptr.2d 233, 851 P.2d 27; People v. Smith (1975) 53 Cal.App.3d 655, 126 Cal.Rptr. 195.) Therefore, construing section 186.22(d) as a penalty provision would not undermine the prosecution's charging authority.
Interpreting the provision as a substantive offense would, however, create potential pleading problems, as this case illustrates. The prosecution's second amended petition alleged in count 1 a violation of section 186.22(d) and identified *875 battery as the underlying offense. Because section 186.22(d) requires a conviction on the underlying offense, the crime of battery was also alleged in a separate count. If section 186.22(d) is a substantive crime, then under the pleadings in this case, battery would be a necessarily included offense of that crime. (See People v. Ortega (1998) 19 Cal.4th 686, 692, 698, 80 Cal.Rptr.2d 489, 968 P.2d 48 [an offense is necessarily included within a charged offense if the accusatory pleading describes the offense in such a way that if committed as specified the lesser offense is necessarily committed].) "`Although the reason for the rule is unclear ... multiple convictions may not be based on necessarily included offenses. [Citations.]' [Citation.]" (Id. at p. 692, 80 Cal.Rptr.2d 489, 968 P.2d 48.) That means petitioner could not be convicted of both battery and violating section 186.22(d). And if he could not be convicted of both charges, he could not be convicted of the latter charge either. In other words, if section 186.22(d) were construed as a substantive offense, it could become a nullity.
As it turns out, the catch 22 that arises when section 186.22(d) is construed as a substantive offense is easily eliminated. By interpreting the statute as a penalty provision, prosecutors would be free to charge a violation of section 186.22(d) along with the predicate offense needed to satisfy that section without running afoul of the necessarily-included-offense rule. Consistent with our duty to retain the effectiveness of voter initiatives (Horwich v. Superior Court, supra, 21 Cal.4th at p. 276, 87 Cal.Rptr.2d 222, 980 P.2d 927), we therefore hold that section 186.22(d) constitutes a penalty provision, and not a substantive offense.
Anticipating this holding, real party in interest argues it does not justify granting petitioner relief as to count 1 of the second amended petition because that count provides sufficient notice of the charge and adequately sets forth a public offense. We agree with the notice argument. As framed, count 1 certainly apprised petitioner of the fact he was being charged with a violation of section 186.22(d). The problem is, the charge was framed as a substantive crime, and as we have explained above, section 186.22(d) is no such thing. When, as here, the facts alleged fail to make out a public offense, a demurrer is proper. (§ 1004.)

DISPOSITION
Let a peremptory writ of mandate issue directing respondent court to vacate its order overruling petitioner's demurrer to count 1 of the second amended petition and to enter a new order sustaining the demurrer with leave to amend. The petition for writ of prohibition preventing respondent court from taking further action against petitioner is denied, the order to show cause is discharged, and the stay of proceedings is vacated.
CROSBY, Acting P.J., and O'LEARY, J., concur.
NOTES
[1]  Unless noted otherwise, all further statutory references are to this code.
[2]  Battery is punishable by a fine, imprisonment in the county jail, or by both fine and imprisonment. (§ 243, subd. (a).) Because it is not punishable with death or imprisonment in state prison, it is a misdemeanor. (§ 17, subd. (a).)
[3]  Section 186.22, subdivision (b)(1) provides, "Except as provided in paragraph (4) and (5), any person who is convicted of a felony committed for the benefit of, at the direction of, or in association with any criminal street gang, with the specific indent to promote, further, or assist in any criminal conduct by gang members, shall, upon conviction of that felony, in addition and consecutive to the punishment prescribed for the felony or attempted felony of which he or she has been convicted, be punished by an additional term of two, three, or four years at the court's discretion, except that if the felony is a serious felony, as defined in subdivision (c) of-Section 1192.7, the person shall be punished by an additional term of five years. If the felony is a violent felony, as defined in subdivision (c) of Section 667.5, the' person shall be punished by an additional term of 10 years."
