
848 A.2d 642 (2004)
381 Md. 157
BOARD OF PHYSICIAN QUALITY ASSURANCE
v.
Paul A. MULLAN.
No. 66, Sept. Term, 2003.
Court of Appeals of Maryland.
May 10, 2004.
*644 Thomas W. Keech, Asst. Atty. Gen. (J. Joseph Curran, Jr., Atty. Gen. of Maryland, on brief), Baltimore, for Petitioner.
John H. Doud, III, Baltimore, for Respondent.
Argued before BELL, C.J., RAKER, WILNER, CATHELL, HARRELL, BATTAGLIA, JOHN C. ELDRIDGE (retired, specially assigned), JJ.
*643 RAKER, Judge.
This case concerns the interpretation of a provision in the Maryland Administrative Procedure Act (APA), Md.Code (1984, 1999 Repl. Vol., 2003 Cum. Supp.) §§ 10-101 to 10-305 of the State Government Article,[1] that permits the summary suspension of a medical doctor's licensesuspension without first giving the licensee notice and an opportunity to be heardwhen "the public health, safety, or welfare imperatively requires emergency action." § 10-226(c)(2)(i). We must determine whether the passage of time between the agency's discovery of potential circumstances demanding summary suspension and the agency's final order to suspend is relevant to a finding that the suspension was imperatively required.

I.
On April 25, 2000, the parent of a minor patient treated by Dr. Paul A. Mullan, a pediatrician, filed a written complaint with the State Board of Physician Quality Assurance (the Board). The complaint alleged that Dr. Mullan had treated her son while under the influence of alcohol on April 10, 2000.
*645 On May 17, 2000, a staff member of the Board visited Dr. Mullan at his office to give him a copy of the complaint as well as a letter from the Board demanding a written response within fifteen days to the parent's allegations. The staff also served Dr. Mullan with a subpoena requesting the medical records of the complaining parent's son and the sign-in sheet that would show all the other patients seen by Dr. Mullan on April 10, 2000. On June 13, 2000, he responded to the complaint by letter through his attorney. Dr. Mullan's response to the allegations indicated that he did not drink alcoholic beverages and that any perception by the patient's mother of glazed eyes and an unsteady gait could be explained by the doctor's various physical ailments that emulated, but were not attributable to, intoxication. In the letter, Dr. Mullan's attorney also claimed, mistakenly, that the requested records and sign-in sheet had been sent to the Board.
As a result of the mistake and other delays, it was not until August 7, 2000 that the Board contacted the parents of all the other patients seen by Dr. Mullan on the day in question. Based on its investigation, on August 23, 2000, the Board summarily suspended Dr. Mullan's medical license under § 10-226(c)(2) of the APA. Pursuant to § 10-226(c)(2)(ii) and the Board's regulations, the Board also provided the doctor with notice and an opportunity for reconsideration of the summary suspension. Availing himself of this option, Dr. Mullan appealed the decision, and in September 2000, a three-day hearing was held before an administrative law judge (ALJ).
The ALJ made the following findings of fact: Of the ten patients seen by Dr. Mullan on April 10, four corroborated the initial parent's allegations, while another three noticed nothing out of the ordinary. On April 10, Dr. Mullan exhibited symptoms of intoxication which included slurred speech, incoherence, trembling hands, staggering, swaying, the mishandling of a cotton culture swab, and abrasiveness and belligerence toward the parents of his patients. Departing from his normal routine that day, Dr. Mullan failed to complete the patients' charts, dictate his diagnoses, and make note of the medications he prescribed. Dr. Mullan, who had been treated for alcoholism since 1979, had admitted to his psychiatrist that he was consuming alcohol in May 1999 and May 2000.
The ALJ recommended affirmance of the summary suspension. Dr. Mullan filed exceptions to the findings, and on April 11, 2001, the Board issued a Final Decision and Order, adopting the ALJ's findings and recommendation and suspending Dr. Mullan as "an emergency action taken to protect the public health and welfare under [§ 10-226(c)(2)]."
Dr. Mullan filed a petition for judicial review of the administrative agency's decision in the Circuit Court for Baltimore County. The Circuit Court affirmed the Board's summary suspension.
Dr. Mullan noted a timely appeal to the Court of Special Appeals. In an unreported opinion, that court reversed the Board's finding that summary suspension was "imperatively required" because of a lack of substantial evidence. The court reasoned that the Board's acquiescence to the delay of four months between the initial filing of the complaint and the decision to suspend, during which Dr. Mullan continued to see patients without complaint from either his patients or the Board, vitiated any evidence that might support the Board's determination that summary suspension was "imperatively required." The court stated as follows:
"By allowing [Dr. Mullan] to treat patients for so long, it seems clear that the [Board] did not perceive an emergency.

*646 "In considering whether there truly was an imperative that required a summary suspension of [Dr. Mullan's] medical license because of a risk to public health and safety, we ask, rhetorically, why the Board would have allowed [him] to treat patients for three months after learning of his conduct if it perceived an emergency. Therefore, we agree . . . that the evidence did not justify a summary suspension, and we shall reverse the Order of Summary Suspension."
The Board filed a petition for writ of certiorari in this Court, 377 Md. Ill, 832 A.2d 204 (2003), presenting the following single question: "If a physician's treatment of his pediatric patients while under the influence of alcohol poses an imminent danger to his patients, does a delay in the investigation of that danger preclude the Board as a matter of law from summarily suspending that physician?"
Before this Court, the Board argues that the Court of Special Appeals erred when it took into consideration the lapse of time between the Board's cognizance of possible misconduct and its decision to suspend summarily. In the Board's view, the only statutory requirement for summary suspension is that there be a threat to the public health, safety, or welfare, measured at the time the decision to suspend summarily is made. If at that time the threat persists, the length of the preceding investigation is irrelevant and should form no part of the consideration of whether the circumstances met the statutory criteria. In the alternative, the Board contends that even if the length of time preceding the decision is taken into consideration, the Board has supplied the substantial evidence necessary to uphold its decision to suspend summarily because whatever delay there might have been was reasonable and, moreover, the result of Dr. Mullan's dilatory and uncooperative legal tactics throughout the investigation.
Dr. Mullan, the respondent, contends that the issue is solely one of statutory interpretation and sufficiency of evidence. Because § 10-226(c)(2) permits summary suspension only when the agency finds a circumstance that "imperatively requires emergency action," the Board was required to show evidence to that effect. It did not do so. The record, says respondent, was devoid of any evidence pointing to a substantial likelihood of serious harm at the time of the summary suspension in August. Instead, only the events of April 10, 2000, were seriously considered by the Board which stipulated that the standard of medical care was not violated that day. The mere inference of a risk of harm from events that occurred four months earlier could not satisfy the statutory burden of proof. The Court of Special Appeals, according to respondent, did not base its decision on the prolonged investigation but rather on the lack of substantial evidence in the record to support a finding that the doctor was a serious threat at the time of the suspension.

II.
The overarching issue in this case, typical of judicial review of agency decisions, is whether there exists substantial evidence to support the agency's factual finding. The parties here disagree as to whether the Board's factual finding with regard to the summary suspension order was supported by "substantial evidence," which is required by the APA for all agency determinations of fact. § 10-222(h)(3)(v); see Board of Physician v. Banks, 354 Md. 59, 68, 729 A.2d 376, 380-81 (1999).
License suspension proceedings before an administrative agency are contested cases within meaning of the APA. § 10-202(d)(1)(ii).[2]*647 As a contested case, these proceedings are subject to judicial review under § 10-222. This Court reviews the final decision of the administrative agency and will scrutinize the decision according to established principles of administrative law. See Spencer v. Board of Pharmacy, 380 Md. 515, 846 A.2d 341 (2004).
Section 10-226(c) governs the revocation or suspensions of licenses under the APA and provides as follows:
(1) Except as provided in paragraph (2) of this subsection, a unit may not revoke or suspend a license unless the unit first gives the licensee:
(i) written notice of the facts that warrant suspension or revocation; and
(ii) an opportunity to be heard.
(2) A unit may order summarily the suspension of a license if the unit:
(i) finds that the public health, safety, or welfare imperatively requires emergency action; and
(ii) promptly gives the licensee:
1. written notice of the suspension, the finding, and the reasons that support the finding; and
2. an opportunity to be heard. The statute opens two paths to the licensing authority when it seeks to suspend or revoke a license. The first path, § 10-226(c)(1), requires that, prior to the effective date of any revocation or suspension, the licensing authority give the licensee (i) written notice of the facts warranting its decision to suspend and (ii) an opportunity to be heard. § 10-226(c)(1); see Maryland Racing Com'n v. Castrenze, 335 Md. 284, 296-97, 643 A.2d 412, 418 (1994).
The second path toward suspension is an exception to the normal route of § 10-226(c)(1), and it is found in § 10-226(c)(2). Section 10-226(c)(2), unlike § 10-226(c)(1), does not require notice and an opportunity to be heard prior to the suspension. Instead, it provides that the licensing authority "may order summarily the suspension," forgoing the notice and hearing requirements of § 10-226(c)(1), provided it satisfies two criteria: First, the licensing authority must find that "the public health, safety, or welfare imperatively requires emergency action." § 10-226(c)(2)(i). Second, the licensing authority must "promptly" give the licensee "written notice of the suspension, the finding, and the reasons that support the finding" as well as "an opportunity to be heard." § 10-226(c)(2)(ii).
The Board has published in the Code of Maryland Regulations (C.O.M.A.R.) standards for summary license suspensions. See C.O.M.A.R. 10.32.02.05. Under these regulations, the "administrative prosecutor bears the burden to show by a preponderance of the evidence that the health, welfare, and safety of the public imperatively requires the Board to issue an order to suspend the respondent's license." C.O.M.A.R. 10.32.02.05(F)(2).[3] Furthermore, the Board has published an interpretive rule in the C.O.M.A.R. defining "imperatively requires" to mean "that an action must be undertaken pursuant to [§ 10-226(c)(2)] as a result of factual contentions which raise a substantial likelihood *648 of" risk of serious harm to the public health, safety, or welfare before an evidentiary hearing governed by the Administrative Procedure Act." C.O.M.A.R. 10.32.02.02(B)(14).
In considering § 10-226(c)(2), we note at the outset the interpretive difficulty that arises from an apparent contradiction within its text. On the one hand, § 10-226(c)(2) grants the Board discretion to issue a summary suspension order. The Board "may order summarily the suspension of a license." The word "may" is generally considered to be permissive, as opposed to mandatory, language. See Brodsky v. Brodsky, 319 Md. 92, 98, 570 A.2d 1235, 1237 (1990); 2A N. Singer, Sutherland on Statutes and Statutory Construction § 57.03 (rev. 4th ed. 1984). We have interpreted the word "may" to connote a permissive, discretionary function of the agency in the interpretation of the APA. See Spencer, 380 Md. at 532-33, 846 A.2d at 351. In this context, "may" indicates that the Board is free to order a summary suspension according to its discretion, provided it fulfills the two requirements in § 10-226(c)(2)(i)-(ii). On the other hand, one of those requirements, § 10-226(c)(2)(i), seems to suggest that the Board must issue a summary suspension because summary suspension is proper only if it is imperatively required.
While the phrase "imperatively requires" in § 10-226(c)(2)(i) might mislead into an interpretation that takes away the Board's discretion to issue summary suspensionsan interpretation that transforms "may" into "must"such an ambiguous and contradictory reading is neither necessary nor reasonable. The phrase "imperatively requires" is found in § 10-226(c)(2)(i), which is a subsidiary of the general discretion to summarily suspend found in § 10-226(c)(2). As the first criterion for a proper summary suspension order, the phrase "imperatively requires" describes the circumstances that will satisfy § 10-226(c)(2)(i)'s requirement of an emergency and signals the degree of exigency contemplated for summary suspension orders. But it does not circumscribe the more general discretion found in § 10-226(c)(2), nor does it require the Board to issue a suspension order when the agency finds § 10-226(c)(2)(i)'s exigency level reached.
In other words, while an emergency that "imperatively requires" summary suspension is necessary for a valid summary suspension order, it does not compel such an order. In addition to the Board's finding of an emergency under § 10-226(c)(2)(i), a summary suspension order requires that the Board exercise its discretion to issue such an order under § 10-226(c)(2). Therefore, the phrase "imperatively requires" only describes a characteristic of a threshold requirement for the ignition of the Board's authority to issue a summary suspension. It does not proscribe the Board's discretion to utilize, or not to utilize, that authority when it is available. The logical, though unusual, potentiality the statute contemplates, then, is a situation where the Board makes a factual finding that satisfies § 10-226(c)(2)(i), a showing of an emergency that "imperatively requires emergency action," but subsequently chooses not to exercise its authority to issue the suspension.
It may seem a little unusual for an agency to choose to refrain from issuing a summary suspension even in the face of exigent circumstances that satisfy § 10-226(c)(2)(i), but that is precisely the nature of discretion. With the enforcement of § 10-226(c)(2) committed to the discretion of the agency, the Board retains flexibility to deal with all the facets of a case that the courts do not have. Furthermore, the discretion granted to the Board is not limitless *649 and is subject to judicial review under the arbitrary or capricious standard. See Spencer, 380 Md. at 529-30, 846 A.2d at 349.
This understanding of the statute reconciles the seemingly contradictory language found in the statute, and it is better than the alternative interpretation, which would first grant discretion to issue the summary suspension but then immediately take it away in the very next clause. Such an illogical reading is to be strongly disfavored, as we "avoid constructions that are illogical, unreasonable, or inconsistent with common sense," Price v. State, 378 Md. 378, 388, 835 A.2d 1221, 1227 (2003), and instead interpret and harmonize statutes as a whole, giving meaning and effect to all parts of the statutory language and refraining from interpretations that render any part of the law surplusage or contradictory. See Dutta v. State Farm, 363 Md. 540, 551, 769 A.2d 948, 954 (2001); Associated Acceptance v. Bailey, 226 Md. 550, 556, 174 A.2d 440, 443-44 (1961) (encountering an apparent contradiction between two parts of a statute and interpreting those parts to harmonize together).
The discretion to issue a summary suspension order if the agency so chooses necessarily includes the discretion to issue the order when the agency chooses. Just as the agency may decide not to issue a summary suspension order under § 10-226(c)(2), even when it finds exigent circumstances under § 10-226(c)(2)(i), the agency also may delay issuing that order under the same statutory provisions. The Court of Special Appeals, in effect, punished the Board for exercising this discretion when it vitiated all the Board's evidence supporting summary suspension because the Board issued the order four months after being put on notice of the possible misconduct.
Giving dispositive weight to the speed with which an agency culminates a complaint into a suspension order unreasonably restricts the ability and discretion of the agency to conduct its investigation and issue a summary suspension based upon credible, substantiated allegations. See, e.g., Pietig v. Iowa Dept. of Transp., Motor Veh. Div., 385 N.W.2d 251, 253 (Iowa 1986) (where statute required suspension "forthwith" after conviction of driving while intoxicated, agency's license suspension four months after conviction, while dilatory and not forthwith, was valid, absent some showing of prejudice); State v. Chavis, 261 S.C. 408, 200 S.E.2d 390, 392 (1973) (noting that when "there is nothing other than an unexplained delay on the part of the reporting officials, unaccompanied by any showing of real prejudice to the driver, the driver is not entitled to any relief because of delay in imposing the suspension" and citing several cases); State v. Pollander, 167 Vt. 301, 706 A.2d 1359, 1363 (1997) (noting that statutory objective of "speedy license-suspension process" in DUI cases was not undermined where suspension occurred a year after process was initiated and where defendant effectuated the delay by his requests for continuances); Sneed v. Department of Public Safety, 343 So.2d 336, 338 (La.Ct.App.1977) (noting that the "`forthwith' mandate of the statute is directed to the Department for the purpose of protecting the public at large from the habitually intoxicated motorist and not to create by implication a prescriptive period to relieve the convicted driver from the penalties of his own misconduct") (quoting State v. Cornelison, 304 So.2d 758, 759 (La.Ct.App.1974)). Nor does it comport with the discretion expressly committed to the agency under § 10-226(c)(2). When investigating potential summary suspensions, an agency should not compromise the thoroughness of its investigation because of the threat of judicial reversal should the investigation take "too long." *650 Consideration of the time period preceding the summary suspension as "evidence" vitiating the Board's factual finding would also create the perverse additional incentive for licensees to delay and not cooperate with the Board's attempts to substantiate complaints. Unquestionably, a licensee under investigation has the right to avail himself or herself of legal counsel and all the protections afforded him or her under law. Nevertheless, a licensee's legal defense, obviously an acceptable and lawful response to the threat of summary suspension, should not be rewarded with the unexpected and unwarranted windfall of precluding summary suspension altogether.
Ultimately, consideration of the delay as vitiating evidence illogically shifts the discretion to order summary suspensions away from the agency and into the hands of the licensee under investigation. Clearly, this result could not have been intended by the Legislature. In fact, in the case sub judice, Dr. Mullan's legal tactics,[4] were responsible for eight of the sixteen weeks between the initial complaint and the issuance of the order. The Board should not be prejudiced for the delays caused by Dr. Mullan's conduct. See, e.g., John P. v. Axelrod, 97 A.D.2d 950, 468 N.Y.S.2d 951, 952-53 (N.Y.App.Div.1983) (holding that the agency could lawfully find an imminent danger to the public and summarily suspend a physician's license, even after a six-year delay, particularly as the delays in going forward were largely attributable to physician's legal actions), aff'd 61 N.Y.2d 891, 474 N.Y.S.2d 474, 462 N.E.2d 1192 (1984).
Our holding today does not require courts to ignore completely the length of the investigatory period when it reviews the summary suspension orders of administrative agencies. Instead, the timing of the administrative agency's issuance of the order could be a relevant factor in determining whether the agency acted arbitrarily or capriciously when it ordered the summary suspension in the first place. Because the issuance of a summary suspension order is committed to the agency's discretion by law, it is subject to judicial review under the arbitrary or capricious standard of § 10-222(h)(3)(vi). See Spencer, 380 Md. at 529-30, 846 A.2d at 349. The arbitrary or capricious standard, as we have stated before, sets a high bar for judicial intervention, meaning the agency action must be "extreme and egregious" to warrant judicial reversal under that standard. MTA v. King, 369 Md. 274, 291, 799 A.2d 1246, 1255-56 (2002).
Therefore, a delay in the issuance of the summary suspension order is a relevant factor in determining whether the agency properly exercised its statutory discretion, judicially reviewed under the extremely deferential arbitrary or capricious standard. The investigatory period, for all the reasons outlined above, should not be weighed as "evidence" in the "imperatively requires" calculus, where it would be reviewed by the courts as a factual finding under the less deferential substantial evidence standard.
The length of the investigatory period leading up to summary suspension does not play a role in the consideration of whether there is substantial evidence to support the agency's factual finding that the situation "imperatively requires emergency *651 action." Instead, the length of the investigatory period should be considered when a court reviews the summary suspension order under the arbitrary or capricious standard of judicial review.

III.
We turn now to our review of whether the Board's factual finding that the summary suspension was imperatively required was supported by substantial evidence. The substantial evidence test, set forth in § 10-222(h)(3)(v) of the APA, requires that an agency's factual determination be supported by "competent, material, and substantial evidence in light of the entire record as submitted." We have further elaborated on the concept of substantial evidence, explaining:
"In applying the substantial evidence test, a reviewing court decides whether a reasoning mind reasonably could have reached the factual conclusion the agency reached. A reviewing court should defer to the agency's fact-finding and drawing of inferences if they are supported by the record. A reviewing court must review the agency's decision in the light most favorable to it[, and] the agency's decision is prima facie correct and presumed valid."
Banks, 354 Md. at 68, 729 A.2d at 380-381 (quotation marks and citations omitted). We apply this standard in the case sub judice.
Respondent argues that the record is devoid of any evidence that Dr. Mullan's practice of medicine posed a threat rising to the level of emergency contemplated by § 10-226(c)(2)(i). We disagree.
The record establishes that Dr. Mullan has struggled with alcoholism since 1979 and had relapsed at least twice as recently as May 1999 and May 2000. Furthermore, the ALJ's finding that Dr. Mullan was treating his patients while intoxicated on April 10, 2000 is not disputed in this Court. Indeed, the record is replete with evidence that Dr. Mullan treated minor patients while he was intoxicated: For example, Dr. Mullan departed from his normal practice of completing the patients' charts and of dictating his diagnoses. He also failed to make note of the medications he prescribed that day. Additionally, five different lay witnesses, who had no connection except that they were the parents of long-time patients of the doctor who were seen by him on April 10, corroborated his intoxicated state that day.
When a pediatrician, with a history of severe alcoholism, renders medical care to children while visibly intoxicated, he exhibits a remarkable lack of sound judgment by his failure to decide not to see patients on that day, even if he could not refrain from using alcohol. Such a lack of sound judgment is sufficient evidence for a reasonable Board to conclude the incident might repeat itself, requiring the immediate suspension of the doctor's license and posing a danger that "imperatively requires emergency action." As this Court has stated, the heart of fact-finding is drawing inferences from facts. Stansbury v. Jones, 372 Md. 172, 183, 812 A.2d 312, 318 (2002). That is what the Board did here, and it was not unreasonable. This Court may not agree with the Board's finding, but that is not enough reason to overturn it, for the test is reasonableness, not rightness, and we cannot substitute our judgment for the agency's in factual determinations. Id., at 183, 812 A.2d at 318.
As we have made clear, the four-month time lapse between the filing of the complaint and the Board's order is irrelevant to our review for substantial evidence but rather comes into play when we consider whether the Board acted in an arbitrary *652 or capricious manner. A four-month delay does not require a finding that the Board was arbitrary or capricious, considering the nature of the investigation. The fact that fully half of the delay can be attributed not to the actions of the Board but to the tactics of Dr. Mullan by not supplying the Board with legitimately relevant investigatory information confirms that the Board did not act arbitrarily or capriciously when it issued the order on August 23, 2000.
In sum, we hold that the length of the investigatory period preceding the issuance of a summary suspension order is not relevant evidence in determining whether an agency's factual finding that the "public health, safety, or welfare imperatively requires emergency action" under § 10-226(c)(2)(i) is supported by substantial evidence. Instead, the length of the investigatory period is a relevant factor in determining whether the agency acted arbitrarily or capriciously when it chose to issue the summary suspension order at that specific time. In the case sub judice, the timing of the Board's issuance of the order was not arbitrary or capricious, and the Board's factual finding that the circumstances imperatively required the summary suspension was supported by enough evidence to survive substantial evidence review.
JUDGMENT OF THE COURT OF SPECIAL APPEALS REVERSED. CASE REMANDED TO THAT COURT WITH DIRECTIONS TO AFFIRM THE JUDGMENT OF THE CIRCUIT COURT FOR BALTIMORE COUNTY. COSTS IN THIS COURT AND IN THE COURT OF SPECIAL APPEALS TO BE PAID BY PAUL A. MULLAN, RESPONDENT.
NOTES
[1]  Unless otherwise indicated, all future statutory references shall be to provisions in the Maryland Administrative Procedure Act, Md. Code (1984, 1999 Repl. Vol., 2003 Cum. Supp.) §§ 10-101 to 10-305 of the State Government Article.
[2]  Section 10-202(d)(1)(ii) provides that a "contested case" includes a proceeding before an agency to determine "the grant, denial, renewal, revocation, suspension, or amendment of a license that is required by statute or constitution to be determined only after an opportunity for an agency hearing."
[3]  It is not disputed in this Court by either party that a finding that emergency action is imperatively required is a factual finding, the burden of which is upon the Board to prove by a preponderance of the evidence. We will assume this is so for purposes of our opinion.
[4]  Dr. Mullan, for example, acting pursuant to legal advice from his attorney, refused to hand over immediately the records sought by the Board on May 17, notwithstanding the fact that the Board had a valid subpoena, and instead demanded that the Board furnish additional legal authority to request the records.
