In Interest of MDJAnnotate this Case
285 N.W.2d 558 (1979)
In the Interest of M. D. J., a child. Steven E. BAY, Petitioner and Appellee, v. M. D. J., a Child, and V. M., his Guardian ad Litem, Respondents and Appellants.
Civ. No. 9631.
Supreme Court of North Dakota.
October 11, 1979.
*559 John E. Jacobson, State's Atty. for Mercer County, Stanton, for petitioner and appellee.
Benjamin C. Pulkrabek, Mandan, for respondents and appellants.
VANDE WALLE, Justice.
M. D. J., a juvenile, has appealed from the findings of fact and order of disposition entered April 23, 1979, by the Mercer County juvenile court, which found M. D. J. to be a delinquent child because he had committed the delinquent act of murder. M. D. J. was placed under the care, custody, and control of the Superintendent of the North Dakota State Industrial School for a period of two years commencing from the date of the order. We affirm.
This court's scope of review, under the Uniform Juvenile Court Act, Chapter 27-20, N.D.C.C., pursuant to Section 27-20-56, has been held to be equivalent to the former procedure of trial de novo. In Interest of D. S., 263 N.W.2d 114 (N.D.1978). Although appreciable weight is given to the juvenile court's findings of fact, this court is not bound in this matter by the "clearly erroneous" rule found in North Dakota Rules of Civil Procedure 52(a). McGurren v. S. T., 241 N.W.2d 690 (N.D.1976).
Reviewing anew the evidence presented in this case we find that on December 29, 1978, at approximately 5:15 a. m., Deputy Sheriff Steven Bay received a radio message to the effect that some people at an address in Hazen, North Dakota, had been shot but that they were alive and sitting up. No names were given to the officer at that time. Bay immediately drove to Hazen. When he arrived at the scene he checked for footprints in the 5 to 8 inches of newly fallen snow but found none leading from the house. He met Officer Nodland and Deputy Sheriff Peterson, who had also been informed of the incident, at the front of the house and requested that they station themselves there while Bay attempted entry by the back door. No further conversation occurred between the officers at that time. Bay was concerned about further shootings and asked the ambulance people, who had *560 recently arrived, to wait outside until called.
With his gun drawn and ready, Bay knocked on the back door. He was dressed in his uniform, which was covered by a parka, but the parka was open, revealing his badge. Bay also had a badge on his cap. Through a glass in the door he saw M. D. J. and his sister, M. E. J.
The girl gestured entry, and Bay entered. He met M. D. J. just inside the back door. Bay asked M. D. J., "Where are your parents?"
M. D. J. replied, "They are upstairs." He paused and then added, "I shot them."
Bay then took M. D. J. into custody and led him toward the front door. The other officers were then let into the house and M. D. J. was left with Officer Nodland while Bay and Peterson hurried upstairs. They found M. D. J.'s parents in their bed. His father was already dead, but his mother still had a weak pulse. She was carried out to the waiting ambulance but died before she reached the hospital.
In the meantime, Nodland kept M. D. J. in custody while he searched the downstairs for other people. He found five more children in addition to M. D. J. and M. E. J. Nodland asked M. D. J. where the gun was and was told it was upstairs under the mattress on M. E. J.'s bed. M. D. J. then showed the gun to Nodland and Bay. The gun and shells were later removed by another officer. The house was secured and M. D. J. was taken to the Mercer County sheriff's office.
In the afternoon, a written statement was obtained from M. E. J. in which she stated that M. D. J. had told her the gun was under her mattress. Later, a search warrant was issued and the house was searched for further weapons, M. D. J.'s pajamas, the bedsheets, and several other items. M. D. J. was charged with delinquency based upon two counts of murder. Prior to the hearing, M. D. J. moved to suppress his statement concerning the shooting of his parents and the location of the pistol. The statement was deemed admissible by the juvenile court. Admission of the pistol into evidence was initially suppressed, but it was later admitted after the petitioner was allowed to complete the record to the juvenile court's satisfaction. The juvenile court found M. D. J. to be guilty of the delinquent act of murder and ordered him to be placed under the care, custody, and control of the Superintendent of the North Dakota Industrial School for a period of two years commencing with the date of the order. M. D. J. has now appealed from this determination of the juvenile court.
As grounds for reversal, M. D. J. contends:
1. The juvenile court erred in failing to suppress M. D. J.'s statement which indicated that he had shot his parents.
2. The juvenile court erred in failing to suppress admission of the murder weapon.
3. The juvenile court judge was not a neutral and impartial judge, but instead was an advocate for the State.
4. The juvenile court erred in failing to give M. D. J. credit for time spent in custody prior to the disposition of this case.I
We consider first the contention that the juvenile court erred when it failed to suppress M. D. J.'s statement that he had shot his parents.
M. D. J. argues that, pursuant to the Uniform Juvenile Court Act, particularly Section 27-20-26(1), N.D.C.C., he was entitled *561 to representation by counsel and that at the time he admitted to Officer Bay that he had shot his parents a proceeding under the Uniform Juvenile Court Act had begun. M. D. J. further relies upon the decision in Escobedo v. Illinois, 378 U.S. 478, 84 S. Ct. 1758, 12 L. Ed. 2d 977 (1964), that statements elicited by the police during interrogation may not be used against a defendant at a criminal trial where the police investigation was no longer a general inquiry but had begun to focus upon a particular individual. In support of his position that a "proceeding" within the meaning of the Juvenile Court Act had begun at the time Officer Bay asked him where his parents were, M. D. J. cites In the Interest of R. W. B., 241 N.W.2d 546 (N.D.1976). R. W. B. involved the termination of parental rights, and this court held that before proceeding with an initial interview with a representative of the investigating social service agency, parents involved in termination-of-rights proceedings are entitled, pursuant to Section 27-20-26(1), N.D.C.C., to benefit of counsel.
In R. W. B., the parents had made statements to an investigator from the county social service center before they were advised of their right to counsel and before they had obtained the services of counsel. This court held that those statements were improperly admitted into evidence because the questions asked by the investigator were designed to elicit evidence of child abuse and that the parents were entitled to be advised of their right to counsel pursuant to Section 27-20-26(1), N.D.C.C., at the time the investigation had focused upon them.
The decision in R. W. B. relied upon In re J. Z., 190 N.W.2d 27 (N.D.1971), also involving termination of parental rights, in which this court noted that a party is entitled to counsel at all stages of any proceeding under the Juvenile Court Act and that termination-of-parental-rights proceedings are a part of the Act. In J. Z., the parents were interviewed by the juvenile supervisor and were not represented by counsel, nor were they advised of a right to counsel. The parents' statements were admitted into evidence. This court held that the parents should have been advised of their right to counsel and should have been afforded the opportunity of consulting with a lawyer before proceeding with the initial interview with the juvenile supervisor because the juvenile supervisor was functioning as a law-enforcement officer "gathering evidence, on the one hand, and, on the other, determining whether there would be court proceedings to terminate parental rights." 190 N.W.2d at 32.
We do not find R. W. B. or J. Z. applicable to the factual situation here present, for in R. W. B. this court stated:"We express no opinion, however, on the necessity for advising a parent of the right to counsel where the investigation involves only the initial screening of the complaint (such as where investigators visit the parent's home based upon an anonymous complaint) or an initial determination of whether sufficient evidence exists to substantiate such complaint. See In re J. Z., supra, 190 N.W.2d at 32." 241 N.W.2d at 556.
And in J. Z.,, this court stated:
"During this initial interview with the parents, the juvenile supervisor was proceeding under N.D.C.C. Sec. 27-20-06, *562 which empowers him in that capacity to make investigations, to receive and examine complaints and `charges of * * * deprivation of a child for the purpose of considering the commencement of proceedings * * *.' He was not simply screening a complaint to determine if there was jurisdiction or if there was no evidence substantiating the complaint. Rather, he was functioning as a law enforcement officer gathering evidence, on the one hand, and, on the other, determining whether there would be court proceedings to terminate parental rights." 190 N.W.2d at 32.
We are not faced with answering the question left unanswered in R. W. B., i. e., whether or not a person must be advised of a right to counsel where the investigation involves only the initial screening of the complaint against him. Here, there was no complaint against M. D. J. The evidence clearly indicates, without contradiction, that at the time Officer Bay approached the residence he knew only that there had been a shooting. He did not know who had been shot or who had done the shooting. He was unfamiliar with the family. There had been a heavy snowfall that night and there were no footprints in the new snow outside the house. Bay assumed the perpetrator of the shooting was still in the house. When Officer Bay approached the house, after circling it, he saw through a window a young girl and a young boy inside. According to his testimony, the young girl gave Bay, whose badge was visible at the time, some sign indicating he could enter. When he entered the house, he met the young boy (M. D. J.) in the entry. The officer's question, "Where are your parents?" cannot be considered an investigation of M. D. J. The question was a natural and proper question which would be asked of any child in the house under the circumstances in which the officer was called to the house.
Nor do we consider the officer's investigation to be an investigation within the meaning of Section 27-20-06(1)(a), N.D. C.C.In re J. Z., supra, and In re R. W. B., supra, indicate that the investigation must focus on the individual before the right to counsel applies. We do not construe the term "investigation" to include the type of question asked by Officer Bay under the factual circumstances involved in this case. At the time the officer asked the question he had simply received a report that persons in the house had been shot; from his observations he concluded no one had left the house since the time of the shooting. There was no "investigation" that focused on any particular person at that time. The fact that M. D. J. was not represented by counsel nor advised of his right to counsel at the time the question was asked does not make M. D. J.'s unsolicited response that he had shot his parents inadmissible.
M. D. J. argues, however, that because Officer Bay testified that he would not have permitted M. D. J. or anyone else to leave the house at the time the question, "Where are your parents?" was asked, the officer had taken M. D. J. into custody and therefore the juvenile was entitled to counsel. We do not agree that the officer's testimony shows M. D. J. was in custody. The scant information given Bay by radio, that some people in a house had been shot, coupled with his lack of further knowledge of the shooting and his observation that there were no prints in the snow indicating that anyone had left the house, were ample reasons for the officer to conclude that no one should be permitted to leave the house at the time he asked M. D. J. where his parents were. But this does not mean that M. D. J. or anyone else was in custody at that time.
*563 We conclude that the juvenile court did not err when it refused to suppress M. D. J.'s statement that he had shot his parents.II
As his second issue M. D. J. argues that the juvenile court erred when, after additional testimony, it reversed its original ruling to suppress the admission of the gun into evidence and permitted the introduction of the gun and all the evidence relative to it.
M. D. J. had told the law-enforcement officers present at the scene that he had shot his parents. At a suppression hearing, the juvenile court found the officers' investigation had focused on M. D. J. immediately after he made this statement. Thus the subsequent questioning of M. D. J. by law-enforcement officers was found to be improper because M. D. J. was not represented by counsel, nor had he been advised of his right to counsel, and the gun, which was located as a result of M. D. J.'s answers to those questions, was suppressed as evidence.
Petitioner had argued, however, that the gun was admissible under the theory of "inevitable discovery" as an exception to the exclusionary rule.
The juvenile judge noted that the petitioner relied upon the search warrant and M. D. J.'s statement as furnishing a basis for either the "independent source" or the "inevitable discovery" exceptions to the "fruit of the poisonous tree" doctrine. Because M. E. J.'s statement had not been offered into evidence at the first hearing on the motions to suppress and because the juvenile judge was unaware how the search warrant was affected by M. E. J.'s statement, he granted the motion to suppress the gun and other evidence surrounding it, with the right of the petitioner to supplement the record at a later date. A subsequent hearing was held, at which M. E. J. testified that M. D. J. had told her where he had hidden the gun. Law-enforcement authorities also testified relative to the search warrant. The trial court found that with the search warrant, which had not been challenged, the law-enforcement authorities would have known exactly where to find the gun because of M. E. J.'s statement that M. D. J. told her he had hidden the gun under her mattress. The judge concluded that the gun was admissible under the inevitable-discovery theory.
According to 3 LaFave Search & Seizure § 11.4, at 621 (1978) [hereinafter cited as "LaFave"], the theory of inevitable discovery had its first clear application in Somer v. United States, 138 F.2d 790 (2d Cir. 1943). There, the court, after holding that the search of a bootlegger's apartment and car was illegal, went on to note:"Possibly, further inquiry will show that, quite independently of what Somer's wife told them, the officers would have gone to the street, have waited for Somer and have arrested him, exactly as they did. If they can satisfy the court of this, so that it appears that they did not need the information, the seizure may have been lawful." 138 F.2d at 792.
The inevitable-discovery theory is a variation of the independent-source theory, which has been held to prevent the exclusion of evidence when knowledge thereof can be attributed to a source other than the source learned of through a constitutional violation. Wong Sun v. United States, 371 U.S. 471, 83 S. Ct. 407, 9 L. Ed. 2d 441 (1963); Silverthorne Lumber Co. v. United States, 251 U.S. 385, 40 S. Ct. 182, 64 L. Ed. 319 (1920), 43 A.L.R.3d 399; LaFave at 617. The substance of these theories appears to be that the evidence so acquired is not tainted by the "fruit of the poisonous *564 tree." Thus in Silverthorne Lumber Co., supra, Justice Holmes wrote:"The essence of a provision forbidding the acquisition of evidence in a certain way is that not merely evidence so acquired shall not be used before the court but that it shall not be used at all. Of course this does not mean that the facts thus obtained become sacred and inaccessible. If knowledge of them is gained from an independent source they may be proved like any others, but the knowledge gained by the Government's own wrong cannot be used by it in the way proposed." 251 U.S. at 392, 40 S. Ct. at 183, 64 L. Ed. at 321.
In this case, petitioner argues that the gun would have been discovered without questioning M. D. J. as to its location because M. D. J.'s sister, M. E. J., also revealed its location when she was questioned later in the day. At the hearing at which supplementary testimony on the motion to suppress was received by the juvenile court, M. E. J. testified that M. D. J. had informed her of the location of the gun shortly after the shooting. It thus appears that the petitioner is urging that the independent-source theory should apply. Petitioner further argues that because law-enforcement authorities had secured a search warrant later in the day authorizing a search of the residence, the gun would have been found without M. D. J.'s statement as to its location. The validity of the search warrant has not been made an issue on this appeal. In this argument, the petitioner appears to be urging the application of the theory of inevitable discovery. However, because of our disposition of this matter, we do not find it necessary to determine whether or not either of these theories should be adopted and applied to the facts of this case.
*565 As we have previously noted, our review on an appeal under Chapter 27-20 is equivalent to the former trial de novo. Although we give appreciable weight to the juvenile court's findings of fact, we are not bound by those findings. We are required to determine whether or not, on proof beyond a reasonable doubt, M. D. J. committed the acts with which he is charged. See Sec. 27-20-29(2), N.D.C.C. In reviewing this entire record we are convinced that there is ample evidencewithout the gunto support a finding beyond a reasonable doubt that M. D. J. shot his parents and is a delinquent child. M. D. J.'s admission that he shot his parents, which we hold to be admissible, is corroborated by M. E. J.'s testimony concerning events which occurred both before and after the shooting. We find further support for our holding in the testimony of the officer who stated that no one had left the house after the shooting, the testimony of the pathologist who examined the bodies, the testimony of the minister, to whom the shooting was first reported, and the youthful age of the other children in the house. These facts clearly substantiate our finding that M. D. J. knowingly and intentionally caused the death of his parents by shooting and that, as a result, M. D. J. is a delinquent child. While the gun may have been the weapon with which the shooting was accomplished, we do not conclude that this evidence was necessary to establish, beyond a reasonable doubt, that M. D. J. committed the acts for which he was found to be delinquent. Therefore, whether or not the juvenile court should have admitted the gun into evidence is of no consequence in our determination of this matter.
In reaching this conclusion, we are mindful of the decision of the United States Supreme Court in Chapman v. California, 386 U.S. 18, 87 S. Ct. 824, 17 L. Ed. 2d 705 (1967), wherein the Court held that "before a federal constitutional error can be held harmless, the court must be able to declare a belief that it was harmless beyond a reasonable doubt." 386 U.S. at 24, 87 S. Ct. at 828, 17 L. Ed. 2d at 710-711. We believe beyond a reasonable doubt that the admission of the gun, if it was error, was harmless error in view of the overwhelming evidence that M. D. J. committed the acts by reason of which he was alleged to be delinquent.III
M. D. J. also urges that the juvenile court judge erred in his memorandum opinion following the first hearing on the suppression motion by setting forth the procedure whereby the petitioner was able to supplement the evidence on the motion to suppress the admission of the gun and thereby secure its admission into evidence. The substance of M. D. J.'s argument is that by discussing in the memorandum opinion the elements necessary for the application of the inevitable-discovery or the independent-source theories, the trial court became an advocate for the petitioner. Because of our disposition of this matter it is not necessary to discuss this issue in detail. However, we have examined the record at length, including the trial court's memorandum decision and the briefs of the parties, and we do not find that the trial court was in error. In his written brief to the trial court before the first hearing on M. D. J.'s motion to suppress, the petitioner had extensively argued the inevitable-discovery theory, including citations to legal authorities and facts which made the theory applicable. The trial court in its memorandum decision did nothing more than set forth the reasons why, on the basis of the evidence before it, the exception was not applicable. Although he permitted the petitioner to supplement the evidence at a later date and, based upon this new evidence which *566 had not been introduced at the first hearing on the motion to suppress, the judge refused to suppress the gun, we find no error. In any event, the petitioner could have moved to supplement the evidence, and we believe the trial court could have granted such a motion.IV
Finally, M. D. J. contends that because he was committed for the maximum term for a delinquent act, he is entitled to be given credit for the time spent in custody pending disposition of this matter by the juvenile court.
M. D. J. was placed under detention on December 29, 1978, and remained under detention until the juvenile court issued its order for disposition on April 23, 1979. The juvenile court ordered that M. D. J. be placed in custody of the Superintendent of the State Industrial School for a period of two years from the date of the order. Section 27-20-36(2), N.D.C.C., provides:"2. An order of disposition committing a delinquent or unruly child to the state industrial school continues in force for two years, excluding any period of time the child is on parole from the institution, or until the child is sooner discharged by the institution. The court which made the order may extend its duration for additional two-year periods subject to like discharge, if: "a. A hearing is held upon motion of the institution, or on the court's own motion, prior to the expiration of the order; "b. Reasonable notice of the hearing and an opportunity to be heard are given to the child and the parent, guardian, or other custodian; and "c. The court finds that the extension is necessary for the treatment or rehabilitation of the child."
M. D. J. argues that he should be given credit for the time spent in custody because Section 12.1-32-02(2), N.D.C.C., provides for credit for time spent in custody as a result of a criminal charge for which a sentence was imposed. He contends that had this been a criminal matter rather than a juvenile matter, he would have received credit for the time spent in custody, and that failure to give him credit violates his equal-protection rights under the Fourteenth Amendment to the United States Constitution.
We cannot conclude that M. D. J. has been denied equal protection of the law because the Juvenile Court Act does not provide for credit for time spent in custody prior to disposition of the matter, whereas the criminal statutes do provide for such credit. The purposes of the adoption of the Juvenile Court Act are spelled out in Section 27-20-01, N.D.C.C. Included in those purposes is "to remove from children committing delinquent acts the taint of criminality and the consequences of criminal behavior and to substitute therefor a program of treatment, training and rehabilitation;. . ." Furthermore, Section 27-20-33(1), N.D.C.C., provides:"1. An order of disposition or other adjudication in a proceeding under this chapter is not a conviction of crime and does not impose any civil disability ordinarily resulting from a conviction or operate to disqualify the child in any civil service application or appointment. A child shall not be committed or transferred to a penal institution or other facility used primarily for the execution of sentences of persons convicted of a crime."
*567 We need not examine in detail the differences between the substance and procedure of the criminal statutes and the Juvenile Court Act or the reasons therefor. One example should be sufficient: If M. D. J. had been tried and convicted under the criminal statutes of this State he could have received a sentence substantially greater in time than the juvenile court imposed in this instance.
M. D. J. relies upon the decision in In re Eric J., 86 Cal. App. 3d 513, 150 Cal. Rptr. 299 (1978), in support of his position. The California court, relying upon People v. Sandoval, 70 Cal. App. 3d 73, 138 Cal. Rptr. 609 (1977), did hold that a provision in the California penal code requiring that credit be given for time spent in custody applied to persons sentenced under their juvenile Act. However, the California juvenile Act permitted sentences to the California Youth Authority up to the maximum jail term which might be imposed for the same offense if committed by a person over the age of 21 years. Failure to give credit for time spent in custody to a person sentenced to the California Youth Authority could result in a longer sentence than his counterpart would serve in the state prison for the same offense, and the California court held this to be a denial of equal protection. Because the North Dakota statutes do not permit the juvenile court to order a person placed in the custody of the Superintendent of the State Industrial School for more than two years from the time of the order except for the extensions allowed under Section 27-20-36, N.D.C.C., we do not find the rationale of the California decisions applicable.
For the reasons stated herein, the order of the juvenile court is affirmed.
ERICKSTAD, C. J., and PEDERSON, PAULSON and SAND, JJ., concur.NOTES
 Section 27-20-26, subd. 1, N.D.C.C., provides:
"1. Except as otherwise provided under this chapter, a party is entitled to representation by legal counsel at all stages of any proceedings under this chapter and, if as a needy person he is unable to employ counsel, to have the court provide counsel for him. If a party appears without counsel the court shall ascertain whether he knows of his right thereto and to be provided with counsel by the court if he is a needy person. The court may continue the proceeding to enable a party to obtain counsel and shall provide counsel for an unrepresented needy person upon his request. Counsel must be provided for a child not represented by his parent, guardian, or custodian. If the interests of two or more parties conflict separate counsel shall be provided for each of them."
 Although the statements were held to be improperly admitted into evidence, the court determined that such error was not prejudicial because the same testimony was elicited from the parents while they were testifying on their own behalf, as well as from the testimony of the parents' expert witness.
 The court noted, however, that the statements made by the parents to the juvenile supervisor were properly admitted because counsel for the parents did not make timely objection to the statements, nor did he move to strike the evidence coupled with a showing of surprise.
 Section 27-20-06, subset. 1-a, N.D.C.C., provides:
"1. For the purpose of carrying out the objectives and purposes of this chapter and subject to the limitations of this chapter or imposed by the court, a juvenile supervisor shall:
"a. Make investigations, reports, and recommendations to the juvenile court."
 The juvenile judge stated:
"The answers did, however, give information which focused investigation on [M. D. J.]. Since no attorney was provided or even offered, I must suppress (under the D. S. case [In Interest of D. S., 263 N.W.2d 114 (N.D.1978)], 27-20-26 and 27-20-27(2) [N.D.C.C.]), the following:
"(1) All statements by [M. D. J.] relative to the location of the gun, and thereafter.
"(2) The gun itself, together with shells, pictures taken of it, and testimony by all persons of its location, condition, or existence and ballistic tests as fruits of the poisoned tree."
 For further discussion of these exceptions to the exclusionary rule see Maguire, "How to Unpoison the FruitThe Fourth Amendment and the Exclusionary Rule," 55 J.Crim.L.C. & P.S. 307 (1964); LaCount & Girese, "The `Inevitable Discovery' Rule, An Evolving Exception to the Constitutional Exclusionary Rule," 40 Albany L.Rev. 483 (1976); Pitler, "`The Fruit of the Poisonous Tree' Revisited and Shepardized," 56 Calif.L.Rev. 579 (1968); Note, 74 Colum.L.Rev. 88 (1974); Note, 5 Hofstra L.Rev. 137 (1976); Comment, 31 U.Miami L.Rev. 615 (1977); Annot., 43 A.L.R.3d 385 (1972).
 While both petitioner and M. D. J. seem to concede that North Dakota has not adopted the theory of inevitable discovery or the theory of independent source, we note the following statement from the decision in In Interest of D. S., supra:
"D. S. further asserts that the .22 caliber rifle and ammunition which were seized from D. S.'s home should also have been suppressed as `fruit' of the unlawfully obtained confession. The `fruit of the poisonous tree' doctrine acts to exclude evidence which is obtained as a consequence of an unlawful official action. Wong Sun v. United States, 371 U.S. 471, 83 S. Ct. 407, 9 L. Ed. 2d 441 (1963). The test of whether the particular evidence is inadmissible `fruit' is to determine whether the evidence was obtained as a consequence of or by exploitation of the unlawful action rather than from an independent source significant to purge the primary taint. Wong Sun, supra; Costello v. United States, 365 U.S. 265, 81 S. Ct. 534, 5 L. Ed. 2d 551 (1961). This doctrine was established as a natural extension of the exclusionary rule to redress violations of constitutional rights. In the instant case, however, we have determined that the violation was of the statutory right to counsel under § 27-20-26, N.D.C.C. Subsection 2 of § 27-20-27, N.D.C.C., expressly excludes the use of a child's extrajudicial statement which is obtained in violation of the Uniform Juvenile Court Act. This subsection also excludes, upon proper objection, `Evidence illegally seized or obtained.' We conclude that the language of subsection 2 of § 27-20-27, N.D.C.C., is sufficiently broad to encompass the `fruit of the poisonous tree' doctrine, whereby evidence obtained in the course of violation of the Uniform Juvenile Court Act is inadmissible as evidence against a child charged with a delinquent act.
"The record clearly reveals, through Deputy Sheriff Lyman's testimony, that the .22 caliber rifle and ammunition were seized at D. S.'s home as a direct result of the knowledge obtained from D. S.'s confession. These items of evidence are `fruits' of the unlawfully obtained confession, and they are therefore inadmissible as evidence against D. S." 263 N.W.2d at 121. [Emphasis in original.]
Whether or not this statement indicates that had knowledge of the rifle been obtained through an "independent" source it would have been admissible, despite the confession of D. S., is not necessary for us to decide today.
 Because there is no jury in a juvenile proceeding under Chapter 27-20, N.D.C.C., we are not concerned with the effect of the admission of the gunif it was error to admit iton a jury. Because we review the matter on appeal in a manner similar to a trial de novo, we need not determine whether or nothad the gun not been admitted into evidencethe juvenile court would have found that M. D. J. committed the acts by reason of which he was alleged to be delinquent.
 Subsection 2 of Section 12.1-32-02, N.D.C.C., provides:
"2. Credit against any sentence to a term of imprisonment shall be given by the court to a defendant for all time spent in custody as a result of the criminal charge for which the sentence was imposed, or as a result of the conduct on which such charge was based. `Time spent in custody' shall include time spent in custody in a jail or mental institution for the offense charged, whether that time is spent prior to trial, during trial, pending sentence, or pending appeal."