
922 P.2d 152 (1996)
83 Wash.App. 523
The STATE of Washington, Appellant,
v.
E.C., Respondent.
No. 35293-8-I.
Court of Appeals of Washington, Division 1.
September 9, 1996.
*153 Angela Y. Griffin, Deputy King County Prosecutor, Seattle, for Appellant.
Dimitri Iglitzin, Schwerin, Burns, Campbell & French, and Catherine A. Chaney, Seattle, for Respondent.
KENNEDY, Acting Chief Judge.
The State appeals the juvenile court's order dismissing with prejudice the charge of child molestation in the first degree brought against E.C. The State contends that the court erred by failing to follow the competency procedures set forth in RCW 10.77. Although we conclude that RCW 10.77 should be followed in cases in which the needs of the juvenile offender do not conflict with that statute, we also conclude that RCW 10.77 does not operate to limit the juvenile court's authority to adequately respond to the needs of a particular juvenile offender when a conflict arises and when departure from the procedures contained in RCW 10.77 will present no substantial danger to others. Because we conclude that the juvenile court acted within its authority and did not abuse its discretion in dismissing the charges against E.C. with prejudice, we affirm.

FACTS
On June 28, 1994, E. C., a developmentally disabled juvenile, was charged with one count of child molestation in the first degree. In an order waiving arraignment, a competency hearing was set for August 26, 1994. At the competency hearing, all parties agreed that E.C. was incompetent to stand trial. After taking testimony and reviewing two psychological reports prepared by mental health professionals who had evaluated E.C. during the two-month period between charging and the competency hearing, the court found E.C. incompetent to stand trial. Based on substantial evidence contained in the psychological reports, the court concluded that E.C., who suffers from educational, cultural, language, and cognitive deficiencies as well as being developmentally disabled, was unlikely to become competent to stand trial in the reasonably near future.
Following the court's decision with respect to incompetency, the State requested that the court stay the proceedings for ninety days as required by RCW 10.77.090.[1] E.C. *154 argued through counsel that RCW 10.77 applies only to adult defendants, and requested that the court dismiss the case with prejudice. Consistent with the psychological reports that E.C. had suffered from severe anxiety during the weeks preceding the competency hearing, defense counsel reported that E.C. had become so obsessed with the August 26 court date that he was unable to focus on any other subject when communicating with defense counsel. Defense counsel expressed concern that E.C., who was due to return to special education classes in the near future, would be unable to function in school if he were faced with another court date. The court granted E.C.'s motion to dismiss with prejudice, stating:
Although Title 10 doesn't specifically provide a procedure, or the procedure that is being requested today of the Court, I would find that the basic purpose of the Statute would not be offended by my dismissing the case today. And that there would be nothing to be gained, but in fact potentially very significant actual damage would occur by continuing this matter.
So I am going to grant the Motion to Dismiss with prejudice.
Report of Proceedings at 14.[2]
The State appeals the juvenile court's order dismissing the charge against E.C. with prejudice.

DISCUSSION
The State contends that RCW 10.77 is applicable to juvenile competency proceedings, and that by refusing to stay proceedings for ninety days and by dismissing the charge against E.C. with prejudice, the juvenile court violated the clear requirements of the statute. E.C. responds that RCW 10.77 is inapplicable to juvenile competency proceedings, and that the juvenile court acted within its inherent authority in dismissing the charge with prejudice and without further delay.
The Constitution mandates that no incompetent person may be tried, convicted, or sentenced for an offense so long as the incompetency *155 continues. State v. Wicklund, 96 Wash.2d 798, 800, 638 P.2d 1241 (1982); RCW 10.77.050. Prior to 1973, Washington courts relied on their inherent judicial authority in making decisions regarding competency. Wicklund, 96 Wash.2d at 801, 638 P.2d 1241 (citing State v. Johnston, 84 Wash.2d 572, 576, 527 P.2d 1310 (1974)). In 1973, the Legislature enacted RCW 10.77, governing the procedures, treatment, and care of those found incompetent to stand trial. "The effect of that legislation was to standardize the procedures to be used in making determinations of competency." Wicklund, 96 Wash.2d at 801, 638 P.2d 1241 (holding that because the power to determine competency is a necessary power of all criminal courts, and because the provisions of RCW 10.77 are not inconsistent with the powers and duties of courts of limited jurisdiction, RCW 10.77 is equally applicable to superior courts and courts of limited jurisdiction).
Title 13 RCW, governing juvenile courts and juvenile offenders, contains no statute relating explicitly to the competency of juveniles. With respect to the disposition of juvenile offenders, RCW 13.04.450 provides in pertinent part that "[t]he provisions of Chapter 13.04 and 13.40 RCW, as now or hereafter amended, shall be the exclusive authority for the adjudication and disposition of juvenile offenders except where otherwise expressly provided." (Emphasis added). E.C. argues that because RCW 10.77 fails to expressly provide that its terms apply to juvenile offenders, the juvenile court's inherent authority over the disposition of incompetent juvenile offenders remains unlimited by the statute. This argument fails to consider other provisions governing the disposition of juvenile offender cases.
Juvenile Court Rule 1.4(b) provides: "The Superior Court Criminal Rules shall apply in juvenile offense proceedings when not inconsistent with these rules and applicable statutes." With respect to competency, CrR 4.2(c) provides in pertinent part: "All procedures concerning the defense of insanity or the competency of the defendant to stand trial are governed by RCW 10.77." Thus we conclude that unless inconsistent with the rules and statutes applicable to juvenile offense proceedings, RCW 10.77 applies to juvenile competency determinations.[3]
Although the goals of the juvenile justice code differ from those of the adult criminal code, see State v. Schaaf, 109 Wash.2d 1, 7-8, 743 P.2d 240 (1987), RCW 10.77 is not inherently inconsistent with the rules and statutes applicable to juvenile offense proceedings. The Juvenile Justice Act of 1977 serves the dual purposes of punishment and rehabilitation. Schaaf, 109 Wash.2d at 10, 743 P.2d 240; State v. Rice, 98 Wash.2d 384, 392, 655 P.2d 1145 (1982). The Act provides:
(2) It is the intent of the legislature that a system capable of having primary responsibility for, being accountable for, and responding to the needs of youthful offenders, as defined by this chapter, be established. It is the further intent of the legislature that youth, in turn, be held accountable for their offenses and that both communities and the juvenile courts carry out their functions consistent with this intent. To effectuate these policies, the legislature declares the following to be equally important purposes of this chapter:
(a) Protect citizenry from criminal behavior;
. . . .
(c) Make the juvenile offender accountable for his or her criminal behavior;
. . . .
(f) Provide necessary treatment, supervision, and custody for juvenile offenders;
. . . .
(j) Provide for a clear policy to determine what types of offenders shall receive punishment, treatment, or both, and to *156 determine the jurisdictional limitations of the courts, institutions, and community services.
RCW 13.40.010(2).
RCW 10.77 sets forth the procedures for the evaluation and treatment of those alleged to be incompetent to stand trial. RCW 10.77.090 provides explicit guidelines for the evaluation, treatment, and, when appropriate, commitment of defendants who have been found to be incompetent to stand trial. By providing for the rehabilitation of defendants who are incompetent to stand trial, and for trial of those incompetent defendants who can be restored to competency within a reasonable time, RCW 10.77 serves the same general purposes as the Juvenile Justice Act. To the extent that the specific provisions of RCW 10.77 are not inconsistent with the rules and statutes applicable to juvenile offense proceedings, or with the needs of a particular incompetent juvenile offender, we conclude that RCW 10.77 applies to juvenile competency determinations.[4]
Although we conclude that RCW 10.77 is generally applicable to juvenile competency determinations, it does not necessarily follow that the juvenile court erred in refusing to stay proceedings for ninety days or in dismissing the charge against E.C. with prejudice. One of the stated purposes of the Juvenile Justice Act is to respond to the needs of juvenile offenders. RCW 13.40.010(2). If the needs of a particular incompetent juvenile offender require early dismissal of charges with prejudice, we hold that the juvenile court retains the authority to so dismiss charges in order to adequately respond to the needs of that juvenile offender, so long as such dismissal poses no substantial danger to others. Although RCW 10.77 should be followed in cases in which the needs of the juvenile offender do not conflict with that statute, it does not operate to limit the juvenile court's authority to adequately respond to the needs of a particular juvenile offender when a conflict arises between the needs of that offender and the provisions of RCW 10.77. When such a conflict arises, and when departure from the procedures contained in RCW 10.77 will present no substantial danger to others, we hold that the goals of the Juvenile Justice Act must take precedence over those provisions contained in RCW 10.77 which were designed to standardize the procedures to be used in making determinations of competency.
Here, because the juvenile court explicitly found based on substantial evidence that "significant actual damage" potentially would occur by following the specific dictates of RCW 10.77, and because the record supports the trial court's determination that E.C. would not likely become competent within ninety days or any other reasonable period of time, and because the record does not indicate that E.C. presents a substantial danger to other persons, we conclude that the juvenile court properly exercised its authority and acted within the bounds of its discretion by dismissing the charge against E.C. with prejudice, and by declining the State's request to stay proceedings for a period of ninety days.
The State articulated no purpose, below or on appeal, that would have been served by delaying dismissal of the charges in this particular case for a period of ninety days, or by dismissal of the charges without prejudice. We can think of no good reason for elevating form over substance in cases where, as here, the primary purposes to be served by a stay have already been substantially accomplished, *157 and where, as here, the trial court determines based on substantial evidence in the record that it is beyond imagination that the juvenile will become competent to stand trial in the reasonable future, and where, as here, there is no evidence in the record that deviation from the standardized procedures contained in RCW 10.77 presents any danger to others.
Affirmed.
GROSSE and AGID, JJ., concur.
NOTES
[1]  RCW 10.77.090 provides that if the court finds a developmentally disabled defendant incompetent to stand trial, it shall stay the proceedings for no longer than ninety days while the defendant undergoes evaluation and treatment. At a hearing to be held on or before the expiration of the ninety-day period, if the court finds that the developmentally disabled defendant is still incompetent "the charges shall be dismissed without prejudice" unless the court finds that the developmentally disabled defendant is a substantial danger to other persons or presents a substantial likelihood of committing felonious acts jeopardizing public safety, and also finds that that there is a substantial probability that the defendant will regain competency within a reasonable period of time. RCW 10.77.090(3). In that event, the proceedings may be stayed for an additional six months, after which the charges shall be dismissed without prejudice if the defendant is still incompetent to stand trial. Where charges are dismissed due to incompetency, the court shall release the defendant unless civil commitment proceedings are commenced.

Here, E.C. had already been professionally evaluated during the two-month period between the filing of charges and the competency hearing. The court made no finding that E.C. is a substantial danger to other persons or that he presents a substantial danger to reoffend; nor did the State request such a finding or argue that further evaluation needed to be done to determine whether E.C. presents such a danger. Although the record indicates that E.C. may have touched the penis of a younger child, it also reflects that E.C. had had no sex education whatsoever prior to the incident, that he had subsequently developed a simplified but concrete understanding that touching other children's private parts is wrong, and that he is a compliant, obedient child who wants to do the right thing. One of the evaluating psychologists expressed willingness to refer E.C. and his parents to a psychologist experienced in working with sexual behavior problems in individuals with developmental disabilities. The record contains a clear inference that E.C.'s parents, who are highly educated, loving parents, were likely to follow through with such referral. There is no indication in the record that the State even considered commencing civil commitment proceedings with respect to E.C.
[2]  Upon the State's request for clarification of the court's basis for dismissing the charge with prejudice, the following exchange transpired:

MS. GRIFFIN [counsel for the State]: Is the Court dismissing it with prejudice because the Court feels that 10.77 does not apply in a juvenile setting?
THE COURT: No.
MS. GRIFFIN: Okay.
THE COURT: I don't want the State simply to turn around next week and refile this case, or wait until he's 18 and then file it downtown. I've determined that he's not competent, that he's not likely to become competent within 90 days. And that under Title 10, is it ordinarily with or without prejudice that it's dismissed?
MS. GRIFFIN: Without, your Honor.
THE COURT: Without?
MS. GRIFFIN: Yes.
THE COURT: That does say "shall be dismissed without prejudice." On that issue I may not have discretion. Aside from the merits of the issue, do you have any legal arguments to make?
MS. BAER [counsel for E.C.]: No, I don't. I don't.
THE COURT: Well, I am going to dismiss it with prejudice specifically because of the problem of the interplay between the juvenile and the adult system, and my finding that it is really beyond my imagination that he would become competent in the reasonable future.
Report of Proceedings at 15-16.
[3]  The explicit exclusion of RCW 10.22 to juvenile offender proceedings found in RCW 13.04.450 is evidence that the legislature generally contemplated the application of Title 10, including RCW 10.77, to juvenile offender proceedings. See RCW 13.04.450 ("The provisions of Chapter 13.04 and 13.40 RCW, as now or hereafter amended, shall be the exclusive authority for the adjudication and disposition of juvenile offenders except where otherwise expressly provided. Chapter 10.22 RCW does not apply to juvenile offender proceedings, including diversion, under Chapter 13.40 RCW.").
[4]  Relying on In re Frederick, 93 Wash.2d 28, 604 P.2d 953 (1980), E.C. also argues that because RCW 10.77 refers exclusively to "the defendant" and fails to address juvenile respondents, it was not intended to apply to juvenile proceedings. A similar argument was rejected by our Supreme Court in In re A, B, C, D, E, 121 Wash.2d 80, 847 P.2d 455 (1993) (holding that the legislature's use of the word "convicted" in RCW 70.24.340(1)(a) did not preclude application of the statute to juvenile offenders, even though juvenile offenders are "adjudicated" to have committed offenses rather than "convicted" of crimes). See also State v. Cheatham, 80 Wash. App. 269, 908 P.2d 381 (1996) (holding that although juveniles are not technically convicted of crimes or felonies, the mere fact that a statute uses the terms "crime" or "felony" in defining an offense does preclude application of the statute to juveniles). We similarly reject E.C.'s argument that use of the term "defendant" in RCW 10.77 precludes its application to juvenile competency determinations.
