
887 A.2d 549 (2005)
389 Md. 656
Anthony GILMER
v.
STATE of Maryland.
No. 14, September Term, 2005.
Court of Appeals of Maryland.
December 7, 2005.
*550 Amy E. Brennan, Asst. Public Defender (Nancy S. Forster, Public Defender, on brief), Baltimore, for Petitioner.
Jeremy M. McCoy, Asst. Atty. General (J. Joseph Curran, Jr., Atty. General, on brief), Baltimore, for Respondent.
Argued before BELL, C.J., RAKER, WILNER, CATHELL, HARRELL, BATTAGLIA and GREENE, JJ.
BATTAGLIA, Judge.
Petitioner, Anthony Gilmer, pursuant to Maryland Code (2001), Section 6-218(b)(2) of the Criminal Procedure Article,[1] seeks review of a judgment of the Court of Special Appeals affirming the Circuit Court's refusal to give him credit for time served for charges unrelated to those for which he was being sentenced, that the State, without a plea bargain, had nolle prossed[2]*551 prior to sentencing. The specific question presented by Gilmer is:
Is a nolle prosequi the equivalent of a "dismissal" for purposes of Criminal Procedure Article Section 6-218(b)(2) which requires a trial court to give credit at sentencing for pre-trial custody on an unrelated offense that results in a "dismissal or acquittal" where a warrant or commitment for the convicted offense was filed during that custody?
Gilmer v. State, 387 Md. 122, 874 A.2d 917 (2005). We hold that, under the circumstances of this case, a nolle prosequi is the equivalent of a "dismissal" for the purpose of Section 6-218(b)(2) of the Criminal Procedure Article.

I. Background
On September 1, 2002, Anthony Gilmer was in pretrial detention at the Baltimore City Detention Center on a charge of attempted murder and had been at the Center since July 2, 2001, a period of 426 days. On September 1, 2002, Gilmer had an altercation with a fellow detainee, Jonathan Blue, over whose turn it was to use the telephone during "passive recreation" time in the "day room," a place where detainees are permitted to engage in activities such as playing cards, watching television, and using the telephone. Gilmer and Blue were separated but then permitted to return to the day room, where Gilmer and Blue continued to argue, and Gilmer, thereafter, repeatedly stabbed Blue with a silver lock blade knife.
Gilmer was charged with attempted first degree murder in violation of Maryland Code (1957, 1996 Repl.Vol.), Section 411A (b) of Article 27,[3] first-degree assault in violation of Maryland Code (1957, 1996 Repl.Vol.), Section 12A-1 of Article 27,[4] openly wearing and carrying a dangerous and deadly weapon with the intent of causing injury in an unlawful manner in violation of Maryland Code (1957, 1996 Repl. Vol.), Section 36 of Article 27,[5] reckless *552 endangerment in violation of Maryland Code (1957, 1996 Repl.Vol.), Section 12A-2 of Article 27,[6] second-degree assault in violation of Maryland Code (1957, 1996 Repl.Vol.), Section 12A of Article 27,[7] and attempted second-degree murder in violation of Maryland Code (1957, 1996 Repl. Vol.), Section 411A (a) of Article 27.[8]
On June 13, 2003, a jury found Gilmer guilty of first and second-degree assault. At sentencing the Circuit Court judge merged the second degree assault into the first degree assault and sentenced Gilmer to fifteen years incarceration. The judge, however, refused to credit the 426 days of confinement that Gilmer had already served on the attempted murder charges that had been nolle prossed by the State prior to sentencing. Gilmer filed an unsuccessful motion for a new trial prior to noting an appeal to the Court of Special Appeals.
Before the Court of Special Appeals, Gilmer contended that the Circuit Court erred in refusing to give him credit for the time he had served in detention for the attempted murder charge, pursuant to Section 6-218(b)(2) of the Criminal Procedure Article and that it also erred in refusing to ask a voir dire question that he had proposed.[9]Gilmer v. State, 161 Md.App. 21, 24, 866 A.2d 918, 920 (2005). The Court of Special Appeals affirmed the denial of the time served credit decision of the trial court and held that a nolle prosequi is not a dismissal under the plain meaning of Section 6-218(b)(2), and therefore, *553 Section 6-218(b)(3)[10] was applicable, and that, pursuant to Section 6-218(b)(3), which allows the court to exercise its discretion in determining whether to grant credit, the judge did not abuse his discretion. Id. at 31, 866 A.2d at 924. To hold otherwise, it noted, could potentially result in double credit received by Gilmer for time served were he later prosecuted for the attempted murder charges. Id. at 29, 866 A.2d. at 923.

II. Standard of Review
The construction of Sections 6-218(b)(2) and (b)(3) of the Criminal Procedure Article implicate a de novo review. Cain v. State, 386 Md. 320, 327, 872 A.2d 681, 685 (2005). Our goal, when interpreting statutes, is to "identify and effectuate the legislative intent underlying the statute(s) at issue." Id.; Serio v. Baltimore County, 384 Md. 373, 863 A.2d 952, 962 (2004), quoting Drew v. First Guaranty Mortgage Corp., 379 Md. 318, 327, 842 A.2d 1, 6 (2003), in turn quoting Derry v. State, 358 Md. 325, 335, 748 A.2d 478, 483 (2000); Pete v. State, 384 Md. 47, 57-58, 862 A.2d 419, 425 (2004); Graves v. State, 364 Md. 329, 346, 772 A.2d 1225, 1235 (2001). The best source of legislative intent is the statute's plain language, and when the language is clear and unambiguous, our inquiry ordinarily ends there. Cain, 386 Md. at 327, 872 A.2d at 685; Serio, 384 Md. at 373, 863 A.2d at 962; Pete, 384 Md. at 57-58, 862 A.2d at 425; Drew, 379 Md. at 327, 842 A.2d at 6; Beyer v. Morgan State University, 369 Md. 335, 349, 800 A.2d 707, 715 (2002); Whack v. State, 338 Md. 665, 672, 659 A.2d 1347, 1350 (1995). When there is more than one reasonable interpretation of a statute, however, the statute is ambiguous. Moore v. State, 388 Md. 446, 453, 879 A.2d 1111, 1114 (2005); Melton v. State, 379 Md. 471, 476-77, 842 A.2d 743, 746 (2004). When the statutory language is ambiguous, we resolve that ambiguity in light of the legislative intent, considering the legislative history, case law, and statutory purpose. See Moore, 388 Md. at 453, 879 A.2d at 1114; Deville v. State, 383 Md. 217, 223, 858 A.2d 484, 487 (2004); Melton, 379 Md. at 476-77, 842 A.2d at 746. "We consider not only the ordinary meaning of the words, but also how that language relates to the overall meaning, setting, and purpose of the act." Moore, 388 Md. at 453, 879 A.2d at 1114; Deville, 383 Md. at 223, 858 A.2d at 487. The statute's provisions must be read in "a commonsensical perspective to avoid a farfetched interpretation." Cain, 386 Md. at 328, 872 A.2d at 685, Serio, 384 Md. at 373, 863 A.2d at 962; Graves, 364 Md. at 346, 772 A.2d at 1235; Frost v. State, 336 Md. 125, 137, 647 A.2d 106, 112 (1994); Dickerson v. State, 324 Md. 163, 171, 596 A.2d 648, 652 (1991). We construe the statute as a whole so that no word, clause, sentence, or phrase is rendered surplusage, superfluous, meaningless, or nugatory. Moore, 388 Md. at 453, 879 A.2d at 1115; Comptroller v. Phillips, 384 Md. 583, 865 A.2d 590 (2005).

III. Discussion
Gilmer contends that Section 6-218(b)(2) is ambiguous because it does not define the term "dismissal." He contends that, based on the two purposes set forth by the Legislature in enacting Section 6-218 of the Criminal Procedure Article, namely to avoid "banked time"[11] and to *554 eliminate "dead time,"[12] it is only proper that the word "dismissal" in Section 6-218(b)(2) of the Criminal Procedure Article be interpreted to include disposition of a case by nolle prosequi, even in the absence of a plea bargain relating to the charge, so that the trial judge was required to give him credit for the time he served in pre-trial detention for attempted murder. Additionally, he argues, Maryland Rule 4-247 makes clear that a nolle prosequi is a dismissal, and, the fact that a charge or charges can still be prosecuted after being nolle prossed is not dispositive because a dismissal also may permit prosecution. By enacting Section 6-218(b)(2), Gilmer asserts that Maryland created a liberty interest[13] for him to obtain credit for his time served and that denying him credit for time served is denying a right protected by the Fourteenth Amendment.
The State, conversely, contends that the Circuit Court properly exercised its discretion under Section 6-218(b)(3) in refusing to award Gilmer credit for his time served on the nolle prossed attempted murder charge because the plain meaning of Section 6-218(b)(2) refers only to an acquittal or dismissal, whereas Section 6-218(b)(3) refers to any case "other than a case described in paragraph (2)." The State argues that only a nolle prosequi entered as part of a plea agreement is the equivalent of a dismissal because the nolle prosequi then has the effect of precluding future prosecution and that to allow any nolle prosequi to constitute a dismissal could create a windfall of double credit for the defendant if he or she were ever convicted of the initial offense which was originally nolle prossed. The State asserts that Section 6-218(b)(2) is clear; it does not list nolle prosequi, and thus, to interpret the word "dismissal" to include nolle prosequi would thereby render Section 6-218(b)(3) a nullity.

A. Section 6-218(b)(2) & (3)
The precursor of Sections 6-218(a) and (b) was Section 638C(a) of Article 27, which was enacted by the General Assembly in 1974, and provided:
Any person who is convicted and sentenced shall receive credit against the term of a definite or life sentence or credit against the minimum and maximum terms of an indictment sentence for all time spent in the custody of any state, county or city jail, correctional institution, hospital, mental hospital or other agency as a result of the charge for which sentence is imposed or as a result of the conduct on which the charge is based, and the term of a definite or life sentence or the minimum and maximum terms of an indeterminate sentence shall be diminished thereby. In any case where a person has been in custody due to a charge that culminated in a dismissal or acquittal, the amount of time that would have been credited against a sentence for the charge, had one been imposed, shall be credited against any sentence that is based upon a charge for which a warrant or commitment was lodged during the pendency of such custody. In all other cases, the sentencing court shall have the discretion to apply credit against a sentence for time spent in custody for another charge or offense.

*555 1974 Md. Laws, Chap. 735, § 1 (emphasis added). The preamble for the Bill established that its purpose was "for providing that under certain circumstances persons shall receive credit against their sentences for any time spent in custody." 1974 Md. Laws, Chap. 735, § 1.
In 1981 legislation was enacted to clarify that "the concept of giving credit against sentence for time spent in custody does not apply to a parolee who commits a subsequent offense and is incarcerated prior to the date on which he is sentenced for the subsequent offense." 1981 Md. Laws, Chap. 721. The language added to the end of Section 638C (a) read:
This section does not apply to a parolee who is returned to the custody of the Division of Correction as a result of a subsequent offense and is incarcerated prior to the date on which he is sentenced for the subsequent offense.
1981 Md. Laws, Chap. 721.
In Fleeger v. State, 301 Md. 155, 482 A.2d 490 (1984), we recognized that one purpose for Section 638C (a) was to avoid "banked time," a "reserve of time established when a defendant spends time in custody that is not yet but may be credited against a valid sentence." Id. at 163, 482 A.2d at 494. Another purpose for enacting Section 638C(a) was to eliminate "dead" time, "time spent in custody that will not be credited to any valid sentence." Id. at 165, 482 A.2d at 495. We explained that Section 638C addressed the problem of "dead" time
by authorizing mandatory credit for any time spent in custody while awaiting trial on an offense for which the defendant is ultimately convicted. The statute also seeks to eliminate dead time that results when a defendant is in custody on one crime but is ultimately convicted of another. By enacting § 638C(a), the General Assembly sought to ensure that a defendant receive as much credit as possible for time spent in custody as is consistent with constitutional and practical considerations. An obvious corollary is that the General Assembly sought to minimize the amount of dead time. Simply stated, we believe that no legitimate legislative policy is advanced by maximizing dead time or by withholding credit that is due a defendant under the crediting statute.
Id. at 165, 482 A.2d at 495 (emphasis added).
In 2001, Section 638C (a) was recodified as Sections 6-218(a) and (b) of the Criminal Procedure Article, 2001 Md. Laws, Chap. 10, § 2, which now provide:
(a) This section does not apply to a parolee who is returned to the custody of the Division of Correction because of a subsequent crime and is confined before being sentenced for the subsequent crime.
(b)(1) A defendant who is convicted and sentenced shall receive credit against and a reduction of the term of a definite or life sentence, or the minimum and maximum terms of an indeterminate sentence, for all time spent in the custody of a state correctional facility, local correctional facility, hospital, facility for persons with mental disorders, or other unit because of:
(i) the charge for which the sentence is imposed; or
(ii) the conduct on which the charge is based.
(2) If a defendant is in custody because of a charge that results in a dismissal or acquittal, the time that would have been credited if a sentence had been imposed shall be credited against any sentence that is based on a charge for which a warrant or commitment was filed during that custody.

*556 (3) In a case other than a case described in paragraph (2) of this subsection, the sentencing court may apply credit against a sentence for time spent in custody for another charge or crime.
The issue before us is whether, like the Court of Special Appeals, we adopt a plain meaning analysis of Section 6-218(b)(2) and determine that the mandatory credit for time served does not apply because the term "nolle prosequi" is absent, or, whether we construe Section 6-218(b)(2) as ambiguous. The decision whether to utilize a plain meaning analysis or an analysis based upon the ambiguity of a statute is made first by looking to see whether the Legislature has provided a definition for the term in question. Deville, 383 Md. at 229, 858 A.2d at 491 ("the legislative history of [the statute] fails to provide an actual definition."); Melton, 379 Md. at 489, 842 A.2d at 753 (holding that the statute was ambiguous because it "provides no definition of the term `violation,' and provides no specific direction as to the proper unit of prosecution."). If there is no definition, we then ask whether there is more than one reasonable interpretation of the statutory language. If there is, the statutory language is ambiguous. Moore, 388 Md. at 453, 879 A.2d at 1114 ("When there is more than one reasonable interpretation of the statute, the statute is ambiguous."); Deville, 383 Md. at 223, 858 A.2d at 487 ("A statute is ambiguous when there are two or more reasonable alternative interpretations of the statute."); Melton, 379 Md. at 476-77, 842 A.2d at 746 ("We have said that ambiguity exists within a statute when there are `two or more reasonable alternative interpretations of the statute.'") (quoting Price v. State, 378 Md. 378, 387, 835 A.2d 1221, 1226 (2003)).
In this case, Section 6-218(b)(2) provides no definition for the term "dismissal." Moreover, the term "dismissal" has different meanings, depending on whether the dismissal is entered with or without prejudice as explicated by the Court of Special Appeals in Parks v. State, 41 Md.App. 381, 397 A.2d 212 (1979), aff'd, 287 Md. 11, 410 A.2d 597 (1980):
The words `with prejudice,' when used in that context, have, of course, a well-established meaning in the law. They signify that the dismissal is final, that the controversy is concluded and cannot be reopened by a new or subsequent action. A dismissal `with prejudice' has been held to be as conclusive of the rights of the parties as if the action had been prosecuted to a final adjudication on the merits adverse to the complainant.
Parks, 41 Md.App. at 386, 397 A.2d at 215 (citations omitted). Later in the opinion, reflecting upon a change in the law under consideration from a dismissal with prejudice to a dismissal without prejudice, the court noted:
[T]he General Assembly has made clear its intent that such a dismissal for failure to comply with the requirements of the Act should serve only to terminate that particular action and not to preclude another. That is what is meant by the phrase `without prejudice.'
Id. at 388, 397 A.2d at 217 (citations omitted).
The term "dismissal" in Section 6-218(b)(2), therefore, absent qualifying language of with or without prejudice, reasonably can be interpreted in either of two ways: one in which the unrelated offense may not be re-prosecuted, or the other in which the unrelated offense subsequently may be prosecuted. As a result, Section 6-218(b)(2) is ambiguous insofar as what constitutes "dismissal."


*557 B. Nolle Prosequi
Section 1-101(k) of the Criminal Procedure Article provides:
"Nolle prosequi" means a formal entry on the record by the State that declares the State's intention not to prosecute a charge.
Rule 4-247 of the Maryland Rules entitled "Nolle Prosequi" governs the disposition of charges by nolle prosequi and its effect, and provides:
(a) Disposition by Nolle Prosequi. The State's Attorney may terminate a prosecution on a charge and dismiss the charge by entering a nolle prosequi on the record in open court. The defendant need not be present in court when the nolle prosequi is entered, but in that event the clerk shall send notice to the defendant, if the defendant's whereabouts are known, and to the defendant's attorney of record.
(b) Effect of Nolle Prosequi. When a nolle prosequi has been entered on a charge, any conditions of pretrial release on that charge are terminated, and any bail posted for the defendant on that charge shall be released. The clerk shall take the action necessary to recall or revoke any outstanding warrant or detainer that could lead to the arrest or detention of the defendant because of that charge.
We had the opportunity to review the history of nolle prosequi in Ward v. State, 290 Md. 76, 82-84, 427 A.2d 1008, 1012-14 (1981), in which Judge John C. Eldridge wrote for the Court:
Apparently the first reported case discussing the entry of a nolle prosequi in a criminal prosecution was Stretton and Taylors Case, 1 Leon. 119, 74 Eng. Rep. 111 (K.B.1588), where the Attorney General entered a `non vult prosequi' for purpose of preventing a private prosecution. Since that time, the nolle prosequi has been a means whereby the government exercises control over pending criminal cases. Thus ... a `Nolle prosequi in criminal practice (for it pertains also to civil), is a declaration of record from the legal representative for the government, that he will no further prosecute the particular indictment or some designated part thereof.' It is `an abandonment of the prosecution,' or a `discontinuance of a prosecution by the authorized attorney' for the state.
* * *
It has been settled since at least the opinion of Chief Justice Hold in Goddard v. Smith, 6 Mod. 262, 2 Salk 456 (1704), that while a nolle prosequi discharges the defendant on the charging document or count which was nolle prossed, and while it is a bar to any further prosecution under that charging document or count, a nolle prosequi is not an acquittal or pardon of the underlying offense and does not preclude a prosecution for the same offense under a different charging document or different count. More than one hundred years ago, this Court stated in State v. Morgan, 33 Md. 44, 46 (1870):
`It is well settled by the authorities that a nolle prosequi ordinarily does not operate as a pardon; but that the accused remains subject to be proceeded against by another indictment for the same offense.'
Later, in Barrett v. State, supra, 155 Md. 636, 142 A. 96 [1928], the Court reiterated that when an indictment was nolle prossed or abandoned, `the case was terminated ... and there can be no further prosecution under that indictment,' but that the discontinuance by the prosecuting attorney was not the *558 equivalent of `confessing a plea of not guilty.'
(citations omitted) (alterations added). Obviously the type of nolle prosequi which does not bar future prosecution under another charging document has the same effect as a dismissal without prejudice.
We also have explored circumstances within which entry of a nolle prosequi precludes future prosecution. Under circumstances where conditions have been attached to the nolle prosequi requiring actions by the defendant, and those conditions have been met, the nolle prosequi has the same effect as a dismissal with prejudice. The underlying facts in State v. Morgan, 33 Md. 44, 46 (1870), involved the entry of a nolle prosequi by the Governor on behalf of the defendant in exchange for payment of costs accrued. 33 Md. at 45. We held that after the Governor's terms were met, and the costs were paid, the defendant was "expressly saved from all further prosecution for or on account of the same offense" and the discharge by nolle prosequi was a final "end and determination" of the suit. Id. at 46. In State v. Brockman, 277 Md. 687, 700, 357 A.2d 376, 384 (1976), we held that the State was precluded from withdrawing its plea agreement where the defendant had already substantially performed the terms of the agreement and that the defendant could elect to have the charges nolle prossed without any reprosecution. We reinforced our Brockman holding in Fleeger, where we noted that, provided the defendant complied with the terms of the plea agreement, the State could not reinstitute the original, nolle prossed charges. Fleeger, 301 Md. at 162, 482 A.2d at 494. We held in Fleeger that a nolle prosequi constitutes a dismissal under Section 638C (a) when it is entered into pursuant to a plea agreement, so that the defendant was entitled to credit served for time served under the nolle prossed charges. Id. at 162, 482 A.2d at 494.
We have also found that a nolle prosequi can function as an acquittal if jeopardy has attached. In Blondes v. State, 273 Md. 435, 330 A.2d 169 (1975), the State entered a nolle prosequi on all charges under the indictment after it had asked for a ruling on admissibility of the chief documentary evidence against the defendant and offered other documentary evidence against the defendant and testimony of a witness in a non-jury case. Id. at 446, 330 A.2d at 175. In finding that jeopardy had attached at the time that the nolle prosequi was entered, Judge Eldridge, again writing for the Court, explained:
One aspect of the double jeopardy prohibition which is firmly settled in this state as a common law principle, is that the entry of a nolle prosequi, without the defendant's consent, and after jeopardy has attached, operates as an acquittal and precludes further prosecution for the same offense ...
On the other hand, where a nolle prosequi is entered before jeopardy attaches, the State is only precluded from prosecuting the defendant further under that indictment, but the defendant may be proceeded against for the same offense by another indictment or information.
Id. at 443-44, 330 A.2d at 173 (citations omitted); see also Hooper v. State, 293 Md. 162, 169 n. 3, 443 A.2d 86, 90 n. 3 (1982) ("[I]f jeopardy had attached at the trial, the nol pros on appeal will ordinarily operate as an acquittal of the underlying charges because of double jeopardy principles."); Ward, 290 Md. at 91, 427 A.2d at 1017 ("[A] nolle prosequi, without the defendant's consent and after jeopardy attaches, `amounts to an acquittal' of the underlying offense."); Friend v. State, 175 Md. 352, 356, 2 A.2d 430 (1938) ("The nolle *559 prosequi entered without the consent of the accused ... placed this defendant in double jeopardy."); cf. Bynum v. State, 277 Md. 703, 709, 357 A.2d 339, 342 (1976) (holding that, although double jeopardy prohibited subsequent prosecution for offenses charged in counts dismissed by a nolle prosequi entered without the consent of the accused after jeopardy has attached, it had no application in the context of the same prosecution which continues on other counts).

C. Nolle Prosequi as Dismissal
The State contends that, based on our interpretation of the word "dismissal" in Director of Finance of Prince George's Co. v. Cole, 296 Md. 607, 465 A.2d 450 (1983), a nolle prosequi does not constitute a dismissal. In Cole, we addressed the meaning of the word "dismissal" in a forfeiture statute, Maryland Code (1957, 1996 Rep. Vol.), Article 27, Section 264(e)(4),[14] which provides:
This Section does not prohibit the trial judge after an acquittal or dismissal from ordering immediate return of all property seized.
We recognized in Cole that Section 264 was originally enacted in 1951 as Article 27, Section 307A, 1951 Md. Laws, Chap. 299 and was significantly amended in 1974 at which time the word "dismissal" was substituted for the phrase "other final determination of such proceedings in favor of the person or persons so arrested," 1974 Md. Laws, Chap. 666, thereby referring to a dismissal with prejudice. We noted in Cole that through its amendment the Legislature explicitly eliminated "other arguably favorable dispositions" such as a nolle prosequi. Cole, 296 Md. at 624, 465 A.2d at 460. There is no comparable legislative history in the case sub judice limiting the term "dismissal" to only one of a final determination.
The State also underscores the reasoning underlying the Court of Special Appeals's holding that the General Assembly was aware of the existence of disposition of a case by nolle prosequi in 1974 when Section 638C(a) was enacted and, therefore, it would have included nolle prosequi in the statute had it so intended. This argument neglects the fact that the Legislature, had it wanted only dismissals with prejudice to trigger the mandatory provisions of Section 638C(a), could have done so by using the term "dismissal with prejudice" in 1974 when it was enacted. We know that the Legislature knew of the term dismissal with prejudice at that time because it used the term in its 1965 enactment of the Interstate Detainer Act, specifically in Article 27, Section 616A(c), which read:
If action is not commenced on the matter for which request for disposition was made, within the time limitation set forth in subsection (a) and above, the court shall no longer have jurisdiction thereof, and the untried indictment shall have no further force or effect; and in such case the court shall enter an order dismissing the untried indictment with prejudice.

1965 Md. Laws, Chap. 628 (emphasis added).
Furthermore, when Section 616A(c) of the Interstate Detainer Act was recodified in 1976 as Article 27, Section 616S(e), it read:
If the untried indictment, information, warrant, or complaint, for which request for disposition is made, is not brought to *560 trial within the time limitation set forth in subsection (b) of this section, the court no longer has jurisdiction, and the untried indictment, information, warrant, or complaint has no further force or effect. In that case, the court upon request of the prisoner or his counsel shall enter an order dismissing the untried indictment without prejudice.

Md.Code (1957, 1996 Rep. Vol.), Art. 27, § 616S(e) (emphasis added).[15] Therefore, in 2001, when Section 6-218(b)(2) was recodified, the General Assembly clearly knew the distinction between with and without prejudice and could have drawn that distinction in the statutory language at issue in this case.
When faced with circumstances where the Legislature was familiar with certain language and did not entertain it, we look to the purpose of the statute. See State v. Thompson, 332 Md. 1, 19, 629 A.2d 731, 740-41 (1993) (holding that, based on the statute's purpose and its legislative history, the legislature would have included specific language regarding drug rehabilitation if it had meant to include it.). As we stated earlier, the purpose for enacting Section 6-218 was to ensure that a defendant "receive as much credit as possible for time spent in custody." Fleeger, 301 Md. at 165, 482 A.2d at 495. Viewed in this light, the term "dismissal," as used in Section 6-218(b)(2), must be interpreted to include dismissal with or without prejudice, including disposition by nolle prosequi.
The State relies on Roberts v. State, 56 Md.App. 562, 468 A.2d 410 (1983), cert. denied, 299 Md. 426, 474 A.2d 219 (1984), for its argument that a nolle prosequi, not entered into pursuant to a plea agreement, lacks the finality of a dismissal or acquittal. In Roberts, the defendant challenged denial of credit for time he had served on handgun charges that had been stetted during sentencing for larceny convictions, credit which he argued was owed pursuant to Section 638C(a). Id. at 565, 468 A.2d at 412.[16] The Court of Special Appeals explained in Roberts that:
The purpose of the language in question in § 638C (a) is to give credit for time spent in custody when there is no other way to credit that time. If an accused is acquitted of a charge for which he had been incarcerated, or if such charge is dismissed, he can never be credited with the time spent in custody against his sentence for that offense because there *561 will be no sentence. But if, while he is incarcerated under one charge, another charge is lodged against him, in the event of an acquittal under the first charge, time spent in custody thereunder can be credited against any sentence imposed on the second.
The situation for which the statute was designed to provide relief does not exist when the first charge is merely stetted because that charge may be eventually tried and may result in conviction and sentence. In such case, the accused will then be credited with the time spent in custody as a result of that charge. If appellant's reading of the statute were correct, should the handgun charge ever be tried and result in a conviction and sentence, he would be entitled to receive credit for time in custody thereon against the sentence that was re-imposed for violation of probation. We do not believe the General Assembly intended such a result.
Id. at 566-67, 468 A.2d at 412 (footnote omitted). This Court has stated many times before, however, that:
In Maryland, unlike some other jurisdictions, we have consistently drawn a sharp distinction between a nolle prosequi and a stet. Although a stet permits an accused to be proceeded against at a later date under the same charging document, a nolle prosequi does not. The nol pros of a charging document or of a count is `a final disposition' of the charging document or count; `there can be no further prosecution under' the nol prossed charging document or count; the matter is `terminated' at that time; and the accused may be proceeded against for the same offense only under a new or different charging document or count.
State v. Moulden, 292 Md. 666, 673, 441 A.2d 699, 702-03 (1982) (citations omitted). Whereas a stet is a mere suspension of the charges which can be freely brought again by the prosecution within one year, a nolle prosequi "leaves the prosecution just as though no such count had ever been inserted in the indictment," id., and removes the accused from "under the imputation of guilt." Barrett, 155 Md. at 638, 142 A. at 97. Accordingly, the analysis of the Court of Special Appeals in Roberts is not applicable in the case sub judice because it is clear that a nolle prosequi, unlike a stet, can act with the finality of a dismissal or acquittal.
The State also asserts that if a nolle prosequi is included in the purview of dismissal for purposes of Section 6-218(b)(2), Gilmer could be awarded a potential windfall of double credit for time served on the nolle prossed charges were he prosecuted and convicted on them and again credited for the time served. Double credit, however, is not in issue because receiving credit for time served for the attempted murder can only occur once under the statute. More importantly, denying a defendant credit for time served on nolle prossed charges is not consistent with the legislative purpose for enacting Section 6-218, to ensure that "a defendant receive as much credit as possible for time spent in custody." Fleeger, 301 Md. at 165, 482 A.2d at 495. The risk of double credit can be easily avoided administratively, whereas the elimination of "dead time" is an essential attribute of Section 6-218(b)(2). The State's argument about double credit is not persuasive.[17]


*562 Conclusion
Accordingly, we hold that a nolle prosequi entered outside of a plea agreement constitutes a dismissal for the purpose of receiving credit for time served under Section 6-218(b)(2), and the Circuit Court erred in denying Gilmer credit for the time served for the nolle prossed charge.[18]
JUDGMENT OF THE COURT OF SPECIAL APPEALS VACATED AS TO THE SENTENCE IMPOSED ON THE CONVICTION FOR FIRST-DEGREE ASSAULT, AND CASE REMANDED TO THE COURT OF SPECIAL APPEALS WITH INSTRUCTIONS TO VACATE THE SENTENCE IMPOSED BY THE CIRCUIT COURT FOR BALTIMORE CITY ON THE FIRST-DEGREE ASSAULT CONVICTION AND REMAND THE CASE TO THAT COURT FOR RESENTENCING PROCEEDINGS CONSISTENT WITH THIS OPINION. COSTS IN THIS COURT AND IN THE COURT OF SPECIAL APPEALS TO BE PAID BY THE MAYOR AND CITY COUNCIL OF BALTIMORE.
Dissenting Opinion by HARRELL, Judge.
I dissent. The Majority opinion errs when it declares ambiguous the use of "dismissal" in § 6-218(b)(2) based only on consideration of that word in isolation. Though it pays lip service to considering the need to "construe the statute as a whole" (Maj. op. at 663, 887 A.2d at 553), the Majority opinion thereafter confines its analysis to (b)(2) and fails to give meaningful consideration to the place "dismissal" occupies within the complete structure of the Legislature's scheme in the larger statutory sub-section of which (b)(2) is but a part. See Johnson v. Mayor & City Council, 387 Md. 1, 11-12, 874 A.2d 439, 446 (2005) ("the commonsensical approach to interpreting statutes includes a review of the general statutory scheme in which the statute in question is found," citing to Frost v. State, 336 Md. 125, 137-38, 647 A.2d 106, 112 (1994)); Forbes v. Harleysville Mutual, 322 Md. 689, 697-99, 589 A.2d 944, 947-48 (1991) (stating that we do not read statutory language "in insolation or out of context [but construe it] in light of the Legislature's general purpose and in the context of the statute as a whole."). When considered in the clear hierarchy established within the totality of § 6-218(b), the claimed ambiguity in (b)(2) disappears.
Section 6-218(b) of the Criminal Procedure Article provides in relevant part:
§ 6-218. Credit against sentence for time
* * * * *
(b) (1) A defendant who is convicted and sentenced shall receive credit against and a reduction of the term of a definite or life sentence, or the minimum and maximum terms of an indeterminate sentence, for all time spent in the custody of a correctional facility, hospital, facility for persons with mental disorders, or other unit because of:
(i) The charge for which the sentence is imposed; or
(ii) The conduct on which the charge is based.

*563 (2) If a defendant is in custody because of a charge that results in a dismissal or acquittal, the time that would have been accredited if a sentence had been imposed shall be credited against any sentence that is based on a charge for which a warrant or commitment was filed during that custody.
(3) In a case other than a case described in paragraph (2) of this subsection, the sentencing court may apply credit against a sentence for time spent in custody for another charge or crime.
(Emphasis added).
It is clear to me from this language that the Legislature intended that trial judges are obliged to grant credit against time served where the relevant charge was disposed of by literal dismissal or acquittal only. In all other cases and by whatever the descriptive name given for the particular disposition, other than by dismissal or acquittal, discretion was granted to judges whether to grant such credit. The only situation in which an ambiguity in the intent of the Legislature might arise would be where a trial court labels a disposition, other than dismissal or acquittal, with a description that constitutes a novelty or gibberish not previously recognized by statute, rule, or common law. Then, and only then, would the functional equivalency type of analysis engaged in here by the Majority be merited. See State v. Glass, 386 Md. 401, 410, 872 A.2d 729, 734 (2005) (a court's analysis "must be undertaken from a commonsensical rather than a technical[] perspective, always seeking to avoid giving the statute a strained interpretation.") (citations omitted).
The Court of Special Appeals was correct in this case, in my view, when it said:
Our decision is in accord with the plain language of § 6-218(b). Subsection (b)(2) uses the terms dismissal and acquittal, not nolle prosequi. We are bound to give these terms their ordinarily understood meaning. See Gillespie v. State, 370 Md. 219, 222, 804 A.2d 426 (2002). Certainly, the General Assembly could have mandated that credit be given for time served on charges that result in a nolle prosequi. That the legislature chose not to do so when it enacted the credit provision thirty years ago, see 1974 Maryland Laws, Ch. 735 § 1, and has taken no steps since then to mandate credit for incarceration on charges that are nol prossed in the ordinary course (as opposed to part of a plea bargain), reflects the legislative will to limit the applicability of that subsection. Any effort on our part to overread the statute would be to venture impermissibly into territory that is under the exclusive control of the General Assembly. See Price v. State, 378 Md. 378, 388, 835 A.2d 1221 (2003) ("`[w]e cannot assume authority to read into the Act what the Legislature apparently deliberately left out'") (citation omitted).
In sum, like the stet discussed in Roberts, [v. State, 56 Md.App. 562, 468 A.2d 410 (1983)] a nolle prosequi entered before trial and not tied to a plea bargain comes within the purview, not of § 6-218(b)(2), but of subsection (b)(3), because it is "a case other than a case described in paragraph (2) of this subsection." In that instance, subsection (b)(3) gives the court discretion to "apply credit against a sentence for time spent in custody for another charge or crime."
Here, the sentencing court exercised its discretion not to award appellant credit for the time he was incarcerated on the nol prossed charged. Appellant suggests no abuse of discretion in this *564 regard, and we find none. We shall not disturb that sentencing decision.
Gilmer v. State, 161 Md.App. 21, 31, 866 A.2d 918, 924 (2005).
To reason as this Court's Majority does, in my view, is to render § 6-218(b)(3) surplusage. See Montgomery County v. Buckman, 333 Md. 516, 524, 636 A.2d 448, 452 (1994) (we read the statute so that "no word, phrase, clause or sentence is rendered surplusage or meaningless."). Section 6-218(b)(3) is intended to operate as a catchall default provision for any disposition other than a literal dismissal or acquittal. To construe, through forced elaboration, a nolle prosequi entered outside of a plea agreement as the functional equivalent of a "dismissal" under (b)(2) is to deprive (b)(3) of its intended significance.
Accordingly, I would affirm the judgments of the Court of Special Appeals and the Circuit Court for Baltimore City.
NOTES
[1]  Maryland Code (2002), Section 6-218(b)(2) of the Criminal Procedure Article, states:

If a defendant is in custody because of a charge that results in a dismissal or acquittal, the time that would have been credited if a sentence had been imposed shall be credited against any sentence that is based on a charge for which a warrant or commitment was filed during that custody.
[2]  We have defined the term nolle prosequi as "an official declaration by the State, announcing that it will not pursue the charges in a particular charging document." In re Anthony W., 388 Md. 251, 258 n. 3, 879 A.2d 717, 720 n. 3 (2005). A nolle prosequi is often shortened and referred to as a nolle prosse or nol pros. See State v. Price, 385 Md. 261, 272, 868 A.2d 252, 258 (2005); see also Black's Law Dictionary 1074 (8th ed.1999) (explaining that a nolle prosequi is "often shortened to nolle pros; nol -pros; nol pro.")
[3]  Maryland Code (1957, 1996 Rep. Vol.), Section 411A(b) of Article 27, stated in relevant part:

(b) Murder in the first degree.  A person who attempts to commit murder in the first degree is guilty of a felony and on conviction is subject to imprisonment for not more than life.
Section 411A has been recodified without substantive changes as Maryland Code (2002), Section 2-205 of the Criminal Law Article.
[4]  Maryland Code (1957, 1996 Rep. Vol., 2001 Supp.), Section 12A-1 of Article 27, stated:

(a) Serious physical injury; use of a firearm.  (1) A person may not intentionally cause or attempt to cause serious physical injury to another.
(2) A person may not commit an assault with a firearm, including:
(i) A handgun, antique firearm, rifle, shotgun, short-barreled shotgun, or short-barreled rifle, as those terms are defined in § 36F of this article;
(ii) An assault pistol, as defined in § 36H-1 of this article;
(iii) A pistol, revolver, or antique pistol or revolver, as those terms are defined in § 441 of this article; and
(iv) A machine gun, as defined in § 372 of this article.
(b) Penalty.  A person who violates this section is guilty of the felony of assault in the first degree and on conviction is subject to imprisonment for not more than 25 years.
Section 12A-1 has been recodified without substantive change as Maryland Code (2002), Section 3-202 of the Criminal Law Article.
[5]  Maryland Code (1957, 1996 Repl.Vol.), Section 36 of Article 27, in relevant part stated:

(a) In general.  (1) Every person who shall wear or carry any dirk knife, bowie knife, switchblade knife, star knife, sand-club, metal knuckles, razor, nunchaku, or any other dangerous or deadly weapon of any kind, whatsoever (penknives without switchblade and handguns, excepted) concealed upon or about his person, and every person who shall wear or carry any such weapon, chemical mace, pepper mace, or tear gas device openly with the intent or purpose of injuring any person in any unlawful manner, shall be guilty of a misdemeanor, and upon conviction, shall be fined not more than $1,000 or be imprisoned in jail, or sentenced to the Maryland Department of Correction for not more than three years.
Section 36 has been recodified without substantive change as Maryland Code (2002), Section 4-101(c) of the Criminal Law Article.
[6]  Maryland Code (1957, 1996 Repl.Vol., 2001 Supp.), Section 12A-2 of Article 27, in relevant part stated:

(a) Creation of substantial risk of death or serious physical injury; penalties.  (1) Any person who recklessly engages in conduct that creates a substantial risk of death or serious physical injury to another person is guilty of the misdemeanor of reckless endangerment and on conviction is subject to a fine of not more than $5,000 or imprisonment for not more than 5 years or both.
Section 12A-2(a)(1) has been recodified without substantive change as Md.Code (2002), Section 3-204(a) of the Criminal Law Article.
[7]  Maryland Code (1957, 1996 Repl.Vol.), Section 12A of Article 27, stated:

(a) General prohibition.  A person may not commit an assault.
(b) Violation; penalties.  A person who violates this section is guilty of the misdemeanor of assault in the second degree and on conviction is subject to a fine of not more than $2,500 or imprisonment for not more than 10 years or both.
Section 12A has been recodified without substantive change as Maryland Code (2002), Section 3-203 of the Criminal Law Article.
[8]  Maryland Code (1957, 1996 Repl.Vol.), Section 411A (a) of Article 27, stated in relevant part:

(a) Murder in the second degree.  A person who attempts to commit murder in the second degree is guilty of a felony and on conviction is subject to imprisonment for not more than 30 years.
Section 411A(a) has been recodified without substantive change as Maryland Code (2002), Section 2-206 of the Criminal Law Article.
[9]  The voir dire question issue is not before us as Gilmer did not raise it in his Petition for Writ of Certiorari.
[10]  Maryland Code, Section 6-218(b)(3) of the Criminal Procedure Article, states:

In a case other than a case described in paragraph (2) of this subsection, the sentencing court may apply credit against a sentence for time spent in custody for another charge or crime.
[11]  "Banked time" is a "reserve of time established when a defendant spends time in custody that is not yet but may be credited against a valid sentence." Fleeger v. State, 301 Md. 155, 163, 482 A.2d 490, 494 (1984).
[12]  "Dead time" is "time spent in custody that will not be credited to any valid sentence." Fleeger, 301 Md. at 165, 482 A.2d at 495.
[13]  A "liberty interest" is an interest that is protected by the Due Process Clause of the Fourteenth Amendment which cannot be arbitrarily denied without due process. U.S. v. Ramos, 401 F.3d 111, 115 (2d Cir.2005).
[14]  Section 264(e)(4) was recodified in 2001 to Section 13-109 of the Criminal Procedure Article. 2001 Md. Laws, Chap. 10, § 2.
[15]  Section 616S(e) was recodified in 1999 as Section 8-503 of the Correctional Services Article and now reads:

(e) Dismissal.  If the untried indictment, information, warrant, or complaint for which request for final disposition is made is not brought to trial within the time limitation established under § 8-502 of this subtitle:
(1) the untried indictment, information, warrant, or complaint has no further force or effect; and
(2) the court, on request of the inmate or the inmate's counsel, shall enter an order dismissing the untried indictment, information, warrant, or complaint without prejudice.
Md.Code (1999), § 8-503(e) of the Correctional Services Article.
[16]  A stet is defined in Maryland Rule 4-248 which, in relevant part, provides:

(a) Disposition by Stet: On motion of the State's Attorney, the court may indefinitely postpone trial of charge by marking the charge "stet" on the docket. The defendant need not be present when a charge is stetted but in that event the clerk shall send notice of the stet to the defendant, if the defendant's whereabouts are known, and to the defendant's attorney of record. A charge may not be stetted over the objection of the defendant. A stetted charge may be rescheduled for trial at the request of either party within one year and thereafter only by order of court for good cause shown.
[17]  The State also contents that if Section 6-218(b)(2)'s use of the word "dismissal" is interpreted to include disposition of a case by nolle prosequi, Section 6-218(b)(3) would be rendered nugatory. This is an inaccurate proposition, as Section 6-218(b)(3), which applies to "a case other than a case described in paragraph (2) of this subsection," may be applicable to cases stetted.
[18]  Because we find that a nolle prosequi constitutes a dismissal for purposes of Section 6-218(b)(2), it is not necessary for us to reach Gilmer's argument that Section 6-218(b)(2) created a "liberty interest" protected by the Fourteenth Amendment.
