
569 N.W.2d 143 (1997)
STATE of Iowa, ex rel. Steve JOHNSON, As County Attorney for Jasper County, Iowa, Appellee,
v.
Garrett ALLEN, II, As Mayor of Mingo, Iowa, Appellant.
No. 96-635.
Supreme Court of Iowa.
September 17, 1997.
*144 Richard E.H. Phelps II, Des Moines, for appellant.
R. Steven Johnson, County Attorney, for appellee.
Considered by McGIVERIN, C.J., and HARRIS, LAVORATO, NEUMAN, and TERNUS, JJ.
TERNUS, Justice.
The City of Mingo has relied on the Jasper County sheriff's department to provide police protection for its residents. The county attorney for Jasper County requested that the City enter into an intergovernmental agreement to pay the county for police services or hire its own law enforcement officer. When the City did neither, the county attorney brought this action for a declaratory judgment and a writ of mandamus ordering the City's mayor to hire a police chief or enter into an intergovernmental agreement. The mayor appeals from the district court's order granting the requested relief. We conclude that although the county attorney is correct in his position that the City must provide police protection to its residents through locally-hired police officers or through an intergovernmental agreement, the duty to do so rests with the city council, not the mayor. Therefore, we reverse.

I. Background Facts and Proceedings.

The parties have stipulated to the facts. The City of Mingo, Iowa is an incorporated municipality with a population of approximately 250 people located in Jasper County, Iowa. It is governed by the mayor-council form of government. See Iowa Code ch. 372 (1995). The City has not had a law enforcement officer for several years and instead has relied on the Jasper County sheriff for police protection. A dispute arose between the City and the sheriff concerning compensation for the services of the sheriff's department. Steve Johnson, the Jasper County attorney, requested appellant Garrett Allen, II, the Mayor of Mingo, Iowa, either to enter into an intergovernmental agreement to pay for the County's police services or to hire a police chief for the City. When the mayor refused to do so, the county attorney brought this action on behalf of the State of Iowa.
In this action, the county attorney sought (1) a declaratory judgment that the mayor has a statutory duty to appoint a police chief unless an intergovernmental agreement provides for police protection, see Iowa Code § 372.4, and (2) a writ of mandamus compelling the mayor's compliance with section 372.4. The mayor's motion to dismiss on the basis the county attorney lacked standing to bring this action was denied by the district court. Following a hearing on the merits of the petition, the court ordered the mayor to appoint a police chief or enter into an inter-governmental agreement. The mayor appealed.

II. Scope of Review.

We review the district court's ruling on a motion to dismiss for correction of errors of law. In re Estate of Voss, 553 N.W.2d 878, 880 (Iowa 1996). Our review of *145 the court's mandamus order is de novo. Nowlin v. Scurr, 331 N.W.2d 394, 396 (Iowa 1983); see Iowa Code § 661.3 (stating mandamus action shall be tried as an equitable action).

III. Standing.

The mayor argues the Jasper County attorney does not have standing to pursue a mandamus action against the mayor for two reasons: (1) the county attorney does not have a sufficient interest in this matter to entitle him to pursue it on behalf of the State; and (2) neither the State nor the County is a real party in interest as required by Iowa Rule of Civil Procedure 2. We find no merit in either contention.
Iowa's mandamus statute provides that an order of mandamus may be issued upon the petition "of the state by the county attorney, when the public interest is concerned." Iowa Code § 661.8 (emphasis added). This statute obviously contemplates the "ex rel." format used by the Jasper County attorney in this case.
Of course, the county attorney's action is appropriate only when "the public interest is concerned." See id. We think the public interest is involved here because the taxpayers of Jasper County have a pecuniary interest in the mayor's compliance with section 372.4. As the situation now stands, Jasper County loses revenue by providing the City of Mingo with police protection without the benefit of an intergovernmental agreement under which the City agrees to pay for these services. Obviously, the County's resources could become even more strained if other cities in Jasper County were to follow the lead of Mingo and rely on the County for police protection. Because this mandamus action addresses a matter of public interest, we conclude the county attorney properly filed the mandamus petition.
That leaves only the mayor's contention that this action was not brought by the real party in interest. Iowa Rule of Civil Procedure 2 requires that every action "be prosecuted in the name of the real party in interest." Rule 2 goes on to state that "a party specially authorized by statute ... may sue in his own name without joining the party for whose benefit the action is prosecuted." We have already held that the county attorney was authorized by statute to bring this action on behalf of the State. Therefore, the requirements of rule 2 have been met.
We affirm the district court's denial of the mayor's motion to dismiss. The county attorney does have standing to pursue this mandamus action.

IV. Responsibility to Provide Police Protection.

In seeking mandamus relief, the county attorney relies on section 372.4, which governs cities having the mayor-council form of government: "The mayor ... shall appoint the marshal or chief of police except where an intergovernmental agreement makes other provisions for police protection or as otherwise provided in section 400.13 [civil service]."[1] The county attorney claims this statute requires that the mayor appoint a police chief if the city council has not otherwise provided for police protection. The mayor argues this interpretation is incorrect for two reasons. First, he contends the decision whether to provide any police protection at all is discretionary, and unless a city chooses to furnish such protection to its residents, the mayor has no duty to appoint a police chief. Alternatively, the mayor claims the decision on how to provide police services is left to the city council and section 372.4 addresses only the manner in which a police chief will be appointed, once the council has decided that is the way it will provide police protection. Because the Mingo city council has not approved the hiring of a police chief, the mayor submits he has no duty to appoint one.
A. City's discretion to provide police protection to its residents. The issue of a city's discretion to provide or not provide police services is answered by examining the role of city government as envisioned by the legislature. *146 Chapter 368 establishes procedures and conditions for the incorporation, consolidation or discontinuation of cities, and for annexation of territory to or severance of territory from an existing city. A petition requesting incorporation, discontinuance or boundary adjustment must include a "[d]escription of existing municipal services, including but not limited to water supply, sewage disposal, and fire and police protection." Iowa Code § 368.11 (emphasis added).
Section 368.14 provides for the appointment of a committee to consider such petitions. This committee is precluded from approving an incorporation "unless it finds that the city to be incorporated will be able to provide customary municipal services within a reasonable time." Id. § 368.17(1) (emphasis added). Similarly, the committee may not approve an annexation of land to an existing city unless "the committee finds that the city will be able to provide to the territory substantial municipal services and benefits not previously enjoyed by such territory." Id. § 368.17(4) (emphasis added).
Clearly, police protection is a "municipal service" as that phrase is used in chapter 368, and our cases reflect that fact. See Citizens of Rising Sun v. Rising Sun City Dev. Comm., 528 N.W.2d 597, 600 (Iowa 1995) (discussing ability of proposed city to provide law enforcement services to meet requirement of section 368.17(1) to provide "customary municipal services"); Dickinson County v. City Dev. Comm., 521 N.W.2d 466, 469-70 (Iowa 1994) (analyzing city's compliance with section 368.17(4)'s requirement that city can provide territory to be annexed with "substantial municipal services," including police protection); City of Decorah v. Peterson, 203 N.W.2d 629, 631 (Iowa 1973) (discussing city's ability to provide police protection as "municipal service" in context of annexation proceeding). Thus, chapter 368 requires all cities to provide police protection as one of the municipal services extended to city residents. See Iowa Code § 362.9 (stating provisions of chapter 368 apply to all cities); see also id. § 362.8 (requiring court to "liberally construe" the city code, which includes chapters 368 and 372, "to effectuate its purpose[ ]" of providing "for the public safety and welfare"). It would be illogical to interpret chapter 368 to require a showing the city or proposed city can provide police protection to its residents as a condition of annexation or incorporation, but not to require that the city actually do so. See United Fire & Cas. Co. v. Acker, 541 N.W.2d 517, 519 (Iowa 1995) (holding court will construe statutes in such a way as to avoid absurd and impractical results).
Based on our interpretation of chapter 368, we reject the mayor's argument that the City of Mingo has discretion to forgo altogether any police protection for its residents. Giving the City such discretion would lead to absurd results, as a close examination of the mayor's rationale illustrates. The mayor argues the City can choose to provide no police services to its residents because the residents of Mingo, as taxpayers of Jasper County, are entitled to police protection from the County. If we were to adopt this reasoning, then the residents of Jasper County, as taxpayers of the State of Iowa, could refuse to hire a county sheriff and rely on the State to provide police protection. Similarly, the citizens of Iowa, as taxpayers of the federal government, could refuse to employ highway patrol officers and simply rely on the federal government for police services. Such a result is illogical and impractical.
In summary, the decision to provide police protection is not discretionary with the City; police protection is one of the basic municipal services the City must provide to its residents to justify its existence under chapter 368. Therefore, it is the City's duty to provide the residents of Mingo with police protection; it is not the duty of Jasper County. We now turn to the role of the mayor in fulfilling the City's duty to provide police services to its residents.
B. Officer or entity of city responsible for police services. Iowa Code section 364.2 provides that the "power of a city is vested in the city council except as otherwise provided by a state law." Pursuant to this statute, the city council has the power to decide how to provide police protection to its residents, unless another statute has given that power to some other city official. Contrary *147 to the suggestion of the county attorney, we do not think section 372.4 places this obligation on the mayor. In fact, it is implicit in the wording of section 372.4 that the obligation to choose the way in which police protection will be provided rests with the city council.
Section 372.4 gives the mayor the duty to appoint the chief of police "except where an intergovernmental agreement makes other provisions for police protection or as otherwise provided in section 400.13 [civil service]." (Emphasis added.) Clearly, the ability to enter into an intergovernmental agreement lies with the city council. See Iowa Code §§ 28E.4 (requiring appropriate action of the governing body before an intergovernmental agreement is effective), 364.2 (placing powers of city in city council). Similarly, it is the city council that has the option to adopt the civil service provisions of chapter 400. See id. § 400.3 ("In cities having a population of less than eight thousand, the city council may, by ordinance, adopt the provisions of this chapter....").
Under the county attorney's interpretation of section 372.4, the mayor would have the power to provide police protection through a police chief if the mayor acted before the city council furnished police services in some other manner. This result creates an unworkable situation. To divide the decision-making responsibility on how to provide police protection between the city council and the mayor only invites problems. For example, if a city council fails to act promptly to renew an intergovernmental agreement for police services before its expiration, can the mayor then appoint a police chief, even though the city council intends to contract for such services with another intergovernmental agreement? Does the mayor's appointment of a chief preclude the council from seeking an intergovernmental agreement? One can envision the confusion of such a decision-making process.
Our interpretation of section 372.4 avoids such problems by keeping the decision on how to provide police protection with the city council. Only when the council has authorized the employment of a police chief is the mayor's duty to make the appointment triggered. The language of section 372.4 supports this conclusion. See State v. Kidd, 562 N.W.2d 764, 765 (Iowa 1997) (holding the fundamental goal of statutory construction is to ascertain the legislature's intent and construe statutes in such a way as to give effect to that intent); State v. Adams, 554 N.W.2d 686, 689 (Iowa 1996) (stating evidence of legislature's intent is found in the language of the statute).
Section 372.4 states the mayor "shall appoint the marshal or chief of police." (Emphasis added.) Chapter 362, which applies to chapter 372, defines the word "shall" as imposing "a duty." Id. §§ 362.1, .2(23). In contrast, it also defines the word "must" as stating "a requirement." Id. § 362.2(14). Significantly, the legislature, by using the word "shall," imposed a duty rather than a requirement. Moreover, section 372.4 refers to the chief of police. As the mayor persuasively argues, the legislature's reference to "the" police chief implies that a decision to appoint "a" police chief has already been made. Compare Webster's Third New International Dictionary 2368 (1993) (defining "the" to mean "a function word [used] to indicate that a following noun ... refers to someone or something previously mentioned or clearly understood from the context or the situation"), with id. at 1 (defining "a" as "a function word [used] before most singular nouns ... when the individual in question is undetermined, unidentified, or unspecified, esp. when the individual is being first mentioned or called to notice"). We think if the legislature intended that the mayor was required to appoint a police chief, as the county attorney contends, it would have said that the mayor must appoint a police chief unless the council has entered into an intergovernmental agreement or has provided for civil service selection procedures.
In summary, the manner in which police services are to be provided to a city's residents is left to the judgment of the city council. The options available to the city council under a council-mayor form of government are outlined in section 372.4. The council can enter into an intergovernmental agreement with another governmental entity to obtain police protection or it can choose to *148 hire its own law enforcement officer. If the council decides to employ a police chief, it can do so pursuant to civil service procedures by simply adopting such procedures, or it can direct the mayor to make the appointment. Once the mayor is authorized by the council to appoint the police chief, the mayor has the obligation to do so.

V. Disposition.

The problem with the mandamus action before us is the identity of the defendant. The county attorney wants an order compelling the mayor to enter into an intergovernmental agreement or to hire a police chief. But the duty to make this decision rests with the city council, not the mayor. Clearly, if the city council had decided to hire a police chief and the mayor had refused to appoint one, the county attorney could properly seek a mandamus order requiring the mayor to comply with his statutory duty of appointment. Until the city council is compelled to make the initial decision, however, it is premature to order the mayor to fulfill a duty that has not yet been triggered by the council's action. See Iowa Code § 661.1 (defining mandamus action as one to obtain an order commanding a person to perform an act that is a duty of that person's office).
Upon our de novo review, we deny the requested relief. We emphasize, however, that our denial is based on the fact the mayor does not have the responsibility to provide police protection to the residents of Mingo. We specifically reject the mayor's suggestion that the mayor has no such responsibility because the City has no such responsibility. The City, as a municipality, must make provision for police services. Unfortunately, we cannot order it to do so here, because the city council is not before us.
AFFIRMED IN PART AND REVERSED IN PART.
NOTES
[1]  Although the statute refers to the appointment of a marshal or a police chief, for simplicity, we will refer only to the police chief in our opinion.
