
592 P.2d 166 (1979)
In the Matter of TWO MINOR CHILDREN.
Dr. Charles R. DICKSON, Administrator of the Division of Mental Hygiene and Mental Retardation of the Department of Human Resources of the State of Nevada, and the Division of Mental Hygiene and Mental Retardation of the Department of Human Resources of the State of Nevada, Petitioners,
v.
The SECOND JUDICIAL DISTRICT COURT of the State of Nevada, IN AND FOR the COUNTY OF WASHOE, DEPARTMENT J, and The Honorable Peter I. Breen, Judge Thereof, Respondents.
DEPARTMENT OF HUMAN RESOURCES of the State of Nevada, DIVISION OF MENTAL HYGIENE AND MENTAL RETARDATION, Appellant,
v.
MINORS UNDER the AGE OF EIGHTEEN YEARS, Respondents.
Nos. 9918, 10127 and 10132.
Supreme Court of Nevada.
March 16, 1979.
*167 Richard H. Bryan, Atty. Gen., Carson City, and Emmagene Sansing, Deputy Atty. Gen., Division of Mental Hygiene & Mental Retardation, Reno, for petitioners.
Calvin R.X. Dunlap, Dist. Atty., Don Nomura and A. Stanyan Peck, Deputy Dist. Attys., Reno, for respondents.

OPINION
MANOUKIAN, Justice:
The district attorney of Washoe County filed a petition in the juvenile court alleging two minors had committed delinquent acts. Upon motion by public defender, counsel for the minors, the court ordered psychiatric evaluations. The psychiatric evaluations indicated that neither was sufficiently competent to assist counsel in defending against the delinquency allegations.
Because the court could not proceed with the delinquency charges, a problem arose as to where the juveniles might be detained until their competence was regained. Hearings were held and testimony received which indicated that due to the absence of available space for the minors in Nevada facilities, an out-of-state confinement was necessary. On April 13, 1977, the court ordered the Division of Mental Hygiene and Mental Retardation of the Nevada Department of Human Resources ("Division") to place the juveniles in an out-of-state facility. That order has been appealed to this Court.
Neither the cost of care nor the financial responsibility for the confinement of the juveniles was addressed in the court order. No agency appeared willing to absorb the *168 cost and consequently the out-of-state facility, the Western Institute for Human Resources in San Rafael, California, has not received payment. On August 12, 1977, the Court ordered the Division to pay the cost of care. That order is also the subject of an appeal. On September 16, 1977, the court ordered Dr. Dickson to appear and show cause why he should not be held in contempt of court for failure to comply with the prior court order directing the Division to pay the cost of confinement. Petitioners now pursue this proceeding for a writ of prohibition prohibiting respondent judge from holding a show cause hearing.
Four issues confront us: (1) Is a writ of prohibition the proper remedy? (2) Are incompetent juvenile accuseds entitled to due process protections before standing trial in delinquency proceedings? (3) May a district court confine incompetent juvenile accuseds in an out-of-state facility? (4) May a district court order a state agency to pay the cost of care associated with this confinement?

(1) Writ of Prohibition.

Regarding the threshold issue of jurisdiction, a writ of prohibition must issue when there is an act to be "arrested" which is "without or in excess of the jurisdiction" of the trial judge under NRS 34.320, Culinary Workers v. Court, 66 Nev. 166, 207 P.2d 990 (1949); cf. Maheu v. District Court, 88 Nev. 26, 493 P.2d 709 (1972), and "where there is not a plain, speedy and adequate, remedy in the ordinary course of law" pursuant to NRS 34.330. Heilig v. Christensen, 91 Nev. 120, 532 P.2d 267 (1975). Preliminarily, confronted with the potential of a contempt order, it is evident that petitioners have no "plain, speedy and adequate remedy in the ordinary course of law." The question of whether the respondent court's action exceeded its jurisdiction is truly the main substantive issue raised in these proceedings. Our discussion of issue three is dispositive of the question of "excess of jurisdiction." Because we conclude that an arguable issue of jurisdiction is presented, we turn now to address the merits of these proceedings.

(2) Juvenile Due Process.

The district court acquired jurisdiction as a juvenile court by the filing of the delinquency petition. NRS 62.030, 62.040(1)(c). Petitioners argue that the youths' present competency is not a prerequisite to the juvenile court's determination of the delinquency charges and that even if the court could postpone the hearings pending a regaining of competency, it cannot order the Division to place the child in an out-of-state facility. They concede that while such a procedure would be permissible if the defendant were an adult, NRS 178.400, the statutes do not apply to children, NRS 169.025, whose cases are governed by the Juvenile Court Act, NRS Chapter 62. That Chapter defines such proceedings as noncriminal in nature.
NRS 62.193 concerns the procedures applicable in hearings on alleged juvenile offenses. Petitioners contend that subsection 4 thereof authorized the court to determine whether in fact a juvenile offense has been committed and to dispose of the matter irrespective of the child's capacity to stand trial. They argue that no prejudice will result to the minors by proceeding with delinquency hearings, even though the children are unable to cooperate with their counsel. Respondent, however, argues that subsection 2 mandates that the child be competent to assist counsel in presenting a defense. Those subsections read as follows:
2. The parties shall be advised of their rights under law in their first appearance at intake and before the court. They shall be informed of the specific allegations in the petition and given an opportunity to admit or deny such allegations.
. . . . .
4. If the court finds on the basis of an admission or a finding on proof beyond a reasonable doubt, based upon competent, material and relevant evidence, that a child committed the acts by reason of which he is alleged to be delinquent, it may, in the absence of objection, proceed immediately to make a proper disposition of the case.
*169 The United States Supreme Court has held that children standing accused in a juvenile court must be accorded due process protections in adjudication of those charges. In re Gault, 387 U.S. 1, 87 S.Ct. 1428, 18 L.Ed.2d 527 (1967). Due process mandates that an accused child be afforded a right to counsel and reasonable opportunity to prepare a defense to the charges. In re Arthur N., 16 Cal.3d 226, 545 P.2d 1345 (1976); United States v. Watts, 513 F.2d 5 (10th Cir.1975); In re F., 11 Cal.3d 249, 520 P.2d 986 (Cal. 1974). Nevada law requires no less.[1] The Supreme Court stated in Gault:
There is no material difference in this respect between adult and juvenile proceedings of the sort here involved. In adult proceedings, this contention has been foreclosed by decisions of this Court. A proceeding where the issue is whether the child will be found to be "delinquent" and subjected to the loss of his liberty for years is comparable in seriousness to a felony prosecution. The juvenile needs the assistance of counsel to cope with problems of law, to make skilled inquiry into the facts, to insist upon regularity of the proceedings, and to ascertain whether he has a defense and to prepare and submit it. The child `requires the guiding hand of counsel at every step in the proceedings against him.' 387 U.S. at 36, 87 S.Ct. at 1448. (Emphasis added. Footnotes deleted.)
Several jurisdictions have permitted juveniles the right to plead and assert the defense of insanity at the adjudicatory stage in juvenile delinquency proceedings. Matter of Stapelkemper, 562 P.2d 815 (Mont. 1977); In re Winburn, 32 Wis.2d 152, 145 N.W.2d 178 (Wis. 1966). Our reading of Kent v. United States, 383 U.S. 541, 86 S.Ct. 1045, 16 L.Ed.2d 84 (1969) and Gault lead us to the conclusion that the concept of due process and fairness mandates permitting juveniles to plead and have tried the defense of insanity. Surely, the right to counsel is meaningless unless that right is interpreted to mean effective counsel, Kent, and counsel cannot be effective, particularly with reference to the merits of a case, without the competent cooperation of his client.
There is an absence of statutory procedure regarding a juvenile court's authority to determine a minor's competence to understand the nature of proceedings pending and to effectively confer with his counsel. A mentally incompetent adult defendant cannot be convicted without a violation of due process until he regains competency to stand trial. Pate v. Robinson, 383 U.S. 375, 86 S.Ct. 836, 15 L.Ed.2d 815 (1966); NRS 178.400. The fitting words of Justice Black transcend the interface of juvenile and adult criminal law:
Where a person, infant or adult, can be seized by the State, charged and convicted for violating a state criminal law, and then ordered by the State to be confined . . ., I think the Constitution requires that he be tried in accordance with the guarantees of all of the provisions of the Bill of Rights made applicable to the States by the Fourteenth Amendment. Undoubtedly this would be true of an adult defendant, and it would be a plain denial of equal protection of the laws  an invidious discrimination  to hold that others subject to heavier punishments could, because they are children, be denied these same constitutional safeguards. In re Gault, supra, at 61, 87 S.Ct. at 1461 (concurring opinion).
Here, the juvenile court had psychiatric evaluations indicating that neither minor could competently assist legal counsel in preparing defenses to the delinquency charges. As a matter of constitutional law, the trial court could go no further with the proceedings. Compare James Paul H. v. Super. Ct. of Riverside County, 77 Cal. App.3d 169, 143 Cal. Rptr. 398 (1978).


*170 (3) Confinement in Out-of-State Facility.

Petitioners next contend that even if not precluded from continuing the delinquency proceedings, the court could not order the Division to confine the minors in an out-of-state facility. We disagree. The psychiatric evaluations, in addition to indicating that the children were incompetent to assist counsel, recommended that the minors, as dangers to society, be confined to a residential treatment facility. NRS 62.240(1) provides:
The court may cause any child adjudged to be within its jurisdiction to be examined by a physician, psychiatrist, psychologist or other qualified person.
See also NRS 62.200(1). Here, the parties acknowledge that jurisdiction of the juvenile court was obtained by the filing of the petitions pursuant to NRS 62.040(1)(c). Dr. Richard Weiher, a psychiatrist who testified for the Division below, stated that the minors are "mentally ill" within the meaning of NRS 433.194 and "emotionally disturbed" as defined in NRS 433.104. He represented that the children pose a potential threat to the community. Dr. Charles Kuhn, also testifying for the Division, concurred in Weiher's diagnosis. The psychiatrists and other representatives of the state claimed that there are no available facilities within the state for the treatment of the minors but that some sort of residential treatment in a secure facility away from the parents was required. Dr. Weiher recommended the Western Institute for Human Resources in San Rafael, California. Accordingly, the district judge ordered the Division to place the minors in the out-of-state facility, and further ordered that a formal review of the children's progress be made 90 days from the date of placement.
Petitioners argue that the court exceeded its power by placing the juveniles in an out-of-state facility. We disagree and hold that where, as here, a juvenile is found to be incompetent to proceed in an adjudication hearing, and the court finds that the youth poses a potential threat to society, the juvenile court can consider a request for an examination to establish whether the youth is competent to proceed. Here the court considered the request as a petition under NRS 62.040(1)(d) (see also NRS 62.130), and NRS 62.240 provides sufficient authority for a court to order such psychiatric treatment and care as it deems in the best interests of the child. See also NRS 62.200(1)(c). Essentially that is what was done here. In the absence of some express statutory provision for dealing with minors determined incompetent to stand trial, our interpretation of the Juvenile Court Act is not inconsistent with its legislative intendment. NRS 62.290, NRS 62.300.
The problems involved in these cases result from the absence of legislation. NRS 178.400 et seq. would adequately deal with an adult charged with a crime, but found incompetent to proceed, but no provision is made for a juvenile in a similar situation. See NRS 169.025. On the other hand, if the minors had not been charged with delinquent acts, civil commitment pursuant to NRS 433A.500 et seq. might have been an available recourse. See NRS 433A.540, 433A.550, 433A.560. The New York Supreme Court has held:
It is inconceivable that the Legislature intended that a juvenile charged with a serious crime, ascertained to be a threat to himself and to society, and found incompetent to proceed, should be returned to his community without some procedure established for his care and treatment. It is hoped that this oversight will soon be corrected by legislative action. In the meantime, the procedures here outlined adequately provide for the protection of the juveniles' rights while upholding the jurisdiction of the Family Court to adequately deal with these circumstances.
People ex rel. Thorpe, etc., v. Clark, 62 A.D.2d 216, 229, 403 N.Y.S.2d 910, 918 (1978). Likewise, it is hoped that our Nevada Legislature will respond to the problem. Until it does, we decline to reverse the order of the district court directing the Division to place the juveniles in an out-of-state facility.
Finally, we turn again to the question of jurisdiction and conclude that the court possessed *171 the authority to place the juvenile incompetents in out-of-state facilities.

(4) The Placement Costs.

Petitioners claim that the court was without authority to order the Division to pay the cost of treatment because no monies were ever appropriated by the Legislature for this purpose. NRS 433A.430(2), 433.374; Nev.Const. Art. 4, § 19; State v. District Court, 85 Nev. 241, 453 P.2d 421 (1969). We are constrained to agree. Chapter 433, NRS, vests broad discretion in the administrator of the Division regarding expenditures for costs of care and treatment of mentally and emotionally disturbed persons. See NRS 433.374.
NRS 62.240(2) provides:
Whenever a child concerning whom a petition has been filed appears to be in need of nursing, medical, surgical or other care, the court may order the parent or other person responsible for the care and support of the child to provide such care. If the parent or other person fails to provide such care, the court may, after due notice, enter an order therefor, and the expense thereof, when approved by the court, shall be a charge upon the county; but the court may adjudge that the person having the duty under the law to support the child pay part or all of the expenses of such case in the manner provided in NRS 62.230. (Emphasis added.)
See also NRS 62.230(1). Although we find no abuse of discretion in the district court's order directing the Division to place the minors in the out-of-state treatment facility, there is clearly no justification for the district court's order holding the Division liable for the payment of costs thereof. NRS 433.374. Compare NRS 62.260; NRS 62.300. There is no evidence that the Division was a "person responsible" for the care of the minors. Assuming that the parents are indigents, the costs of care and treatment of the minor children shall be a charge upon the county. NRS 62.230, 62.240, 62.260.
Accordingly, the order directing the Division to pay the costs of treatment is reversed and the writ of prohibition prohibiting the respondent judge from holding a show cause hearing is granted. The placement order is affirmed, and the county ordered to pay the costs of care and treatment.[2] The trial court's orders are in all other respects affirmed.
MOWBRAY, C.J., and THOMPSON, J., concur.
BATJER, Justice, with whom GUNDERSON, Justice agrees, concurring in part and dissenting in part:
I respectfully dissent from that part of the majority opinion which appears to hold[1] that the district court could order the Division of Mental Hygiene and Mental Retardation of the Nevada Department of Human Resources to confine the minors in an out-of-state facility had the minors first been committed to or placed in the custody of the Division.
The order of the district court, if read in isolation, seems to "order the Division to confine the minors in an out-of-state facility"; however, when read together with the entire record, it is clear that the only duty to be performed by the Division was to physically transport the minors to that facility. NRS 62.300. They were not committed to or placed in the custody of the Division, but were placed directly by the court in the out-of-state facility.
Jurisdiction of the district court does not extend to the function of determining what course of action should be taken nor should it assume the latitude to substitute its appraisals and conclusions for those of the Division.
*172 The decisions to provide mental health service, which and how many services to provide and where and how to provide them, are legislative and executive decisions requiring a balancing of public interests which the courts are neither authorized nor suited to direct. In Galloway v. Truesdall, 83 Nev. 13, 31, 442 P.2d 237, 249 (Nev. 1967), this Court said:
The courts must be wary not to tread upon the prerogatives of other departments of government or to assume or utilize any undue powers. If this is not done, the balance of powers will be disturbed and that cannot be tolerated for the strength of our system of government and the judiciary itself is based upon that theory.
Cf. Jones v. Beame, 45 N.Y.2d 402, 380 N.E.2d 277 (1978); Blaney v. Commissioner of Correction, 372 N.E.2d 770 (Mass. 1978).
It is not to be inferred that Division action could ever be above judicial review or beyond the scope of the extraordinary writs, NRS ch. 34. Our courts will always possess the authority to set aside decisions of the Division if they are arbitrary or illegal.
I agree with the majority that the juvenile division of the district court had the power to directly place the minors in the out-of-state facility, NRS 62.040; NRS 62.240; NRS 62.200(1)(c); that the cost was a proper charge against the county of their legal residence, NRS 62.240(2), and that the district court was without authority to order the Division to pay the cost of treatment at the out-of-state facility. I concur in the remainder of the majority opinion.
GUNDERSON, J., concurs.
NOTES
[1]  NRS 62.195(2) states in part that: If a child is alleged to be delinquent . . . the child and his parents, guardian or custodian shall be advised by the court or its representative that the child is entitled to be represented by counsel at all stages of the proceedings. If counsel is not retained for the child, or if it does not appear that counsel will be retained, counsel shall be appointed for the child, unless waived. . .
[2]  Our holding is not intended to foreclose the county from proceeding under NRS 62.230(2) or NRS 62.240(2) for a court order for partial or total reimbursement.
[1]  In the majority opinion it is written:

"Petitioners next contend that even if not precluded from continuing the delinquency proceedings, the court could not order the Division to confine the minors in an out-of-state facility. We disagree."
