
381 N.W.2d 102 (1986)
221 Neb. 783
Takeo UTSUMI, Appellant,
v.
CITY OF GRAND ISLAND, a Political Subdivision, and Martin Todd, Appellees.
Nos. 84-621, 85-563.
Supreme Court of Nebraska.
February 7, 1986.
*103 Hal W. Anderson, of Berry, Anderson, Creager & Wittstruck, Lincoln, for appellant.
Kenneth H. Elson, Grand Island, for appellees.
KRIVOSHA, C.J., and BOSLAUGH, WHITE, HASTINGS, CAPORALE, SHANAHAN, and GRANT, JJ.
KRIVOSHA, Chief Justice.
The appellant, Takeo Utsumi, filed suit in the district court for Hall County, Nebraska, against the City of Grand Island, a political subdivision, and Martin Todd, a police officer employed by the City of Grand Island. In his fourth amended petition, Utsumi alleged, in substance, that on April 21, 1980, Dreisbach's Steakhouse was robbed by an individual who fled the premises following the robbery. Utsumi alleged that he then pursued the robber in a westerly direction for approximately one block because, as he alleges, he requested Officer Todd to pursue the fleeing robber but Todd failed, refused, and neglected to perform his duties, in that he failed and refused to apprehend the robber. Utsumi further alleged that the robber, while being pursued by him, shot at Utsumi once and missed, and subsequently shot him in the right leg, causing severe injuries. Utsumi sought judgment against the City of Grand Island and Todd for his injury sustained by reason of having been shot by the robber, which, he maintains, was proximately caused by reason of Todd's failing and refusing to pursue and apprehend the felon.
The petition contained no allegations that Utsumi had in any manner complied with the requirements of the Political Subdivisions Tort Claims Act, Neb.Rev.Stat. §§ 23-2401 to 23-2420 (Reissue 1983), by making a claim in writing to the City of Grand Island, as required by § 23-2416, within 1 year after the claim accrued.
The City of Grand Island filed a demurrer to the fourth amended petition on the ground that it did not state facts sufficient to constitute a cause of action against the City of Grand Island. The demurrer was sustained and, when Utsumi failed to plead *104 further, the action as to the City of Grand Island was dismissed with prejudice.
The defendant Todd ultimately filed an answer to the fourth amended petition, generally denying the allegations of plaintiff's fourth amended petition and specifically alleging that Utsumi "knew and appreciated the danger of pursuing and chasing the armed robber, [and] voluntarily or deliberately exposed himself to that danger, and as a proximate result of that danger [sustained] the injury...." Todd further alleged that Utsumi was contributorily negligent for a number of reasons more particularly set out in the answer. Todd's answer to the fourth amended petition concluded by alleging that "whatever injuries and damages plaintiff sustained as a result of being shot by the armed robber were the direct and proximate result of the plaintiff's contributory negligence and assumption of risk." (Emphasis supplied.) Thereafter, Todd filed a motion for summary judgment. On July 23, 1984, the district court for Hall County, Nebraska, sustained the motion for summary judgment and dismissed the action against Todd.
Utsumi appeals these two orders, maintaining that the district court was in error. We believe that the district court was not in error and that the judgments dismissing the action as to both the City of Grand Island and the appellee Todd must be affirmed.
We have frequently held that a motion for summary judgment shall be granted if the pleadings, depositions, and admissions on file, together with the affidavits, if any, show that there is no genuine issue as to any material fact and that the moving party is entitled to a judgment as a matter of law. Moore v. American Charter Fed. Sav. & Loan Assn., 219 Neb. 793, 366 N.W.2d 436 (1985); Witherspoon v. Sides Constr. Co., 219 Neb. 117, 362 N.W.2d 35 (1985); Gilbreath v. Ridgeway, 218 Neb. 822, 360 N.W.2d 474 (1984). We believe that such is the case with regard to the claim against Todd. Moreover, where the petition fails to state facts sufficient to constitute a cause of action, the petition is subject to a demurrer. See, Neb.Rev.Stat. § 25-806 (Reissue 1979); Johnson v. Ruhl, 162 Neb. 330, 75 N.W.2d 717 (1956). As we shall point out, the petition fails to state sufficient facts as to the City of Grand Island and thus is subject to attack by demurrer.
The petition, insofar as it sought relief against the City of Grand Island, failed to allege that Utsumi had complied with the provisions of the Political Subdivisions Tort Claims Act. This was a fatal defect. In Campbell v. City of Lincoln, 195 Neb. 703, 240 N.W.2d 339 (1976), a case involving a similar question, we affirmed the action of the district court in sustaining a demurrer filed by the city of Lincoln when the plaintiff's petition failed to allege that he had complied with the provisions of the Nebraska Political Subdivisions Tort Claims Act prior to the institution of the action. In holding that the plaintiff's petition failed to state a cause of action, we said at 712-13, 240 N.W.2d at 344: "The notice of claim requirements of the Nebraska Political Subdivisions Tort Claims Act is a condition precedent to the institution of suit against a political subdivision...." The failure to allege that the condition precedent had been met was a fatal defect. As we observed in Sole v. City of Geneva, 106 Neb. 879, 881, 184 N.W. 900 (1921):
When a privilege or right is conferred by statute on certain prescribed conditions, and a party desires to avail himself of such privilege or right by bringing action for the enforcement thereof, he must allege and prove all the facts essential to a strict compliance with the prescribed conditions.
(Emphasis supplied.) See, also, Delozier v. Village of Magnet, 104 Neb. 765, 178 N.W. 619 (1920).
Utsumi's failure to allege that he had made claim as required by § 23-2416 and had otherwise complied with the provisions of the Political Subdivisions Tort Claims Act rendered his petition defective and subject to demurrer. The trial court was correct in sustaining the demurrer, and when Utsumi elected not to further plead within *105 the time granted by the court, the district court was correct in dismissing the action as to the City of Grand Island.
We turn, then, to whether the district court was correct in granting summary judgment in favor of the appellee Todd. While this court has not previously held that if a peace officer, in the course of his duties, fails to take such action as would prevent harm to an individual to whom he had a duty, there is liability on the part of the municipality employing the peace officer and the officer as well, Utsumi argues that we should do so in this case. We need not, however, accept Utsumi's invitation, because even assuming, though not deciding, that such a cause of action could exist under an appropriate set of facts, the allegations of Utsumi's petition conclusively establish that Utsumi is, as a matter of law, barred from recovery, either under the doctrine of assumption of risk or by reason of his own contributory negligence. Therefore, Todd is entitled to judgment as a matter of law. We believe that no reasonable person could reach any other conclusion.
As we observed in Garcia v. Howard, 200 Neb. 57, 60, 262 N.W.2d 190, 192 (1978): "Ordinarily the questions of negligence, contributory negligence, and assumption of risk are for the jury, but where the facts adduced with respect to those questions are such that reasonable minds can draw but one conclusion therefrom, a directed verdict is proper." In the instant case, if we accept all of Utsumi's allegations as true, reasonable minds could draw but one conclusion regarding Utsumi's voluntary pursuit of an armed robber; therefore, since the granting of a directed verdict would be appropriate where evidence was adduced, the granting of a summary judgment was correct where, as here, the allegations of the plaintiff's petition establish that the plaintiff is barred from recovering as a matter of law.
To suggest that one who voluntarily pursues an armed robber does not know or appreciate the danger of his action is simply too much to ask. No reasonable mind could conclude anything other than that one who pursues an armed robber is exposing himself to potential danger and injury. That knowledge of the danger bars any right of recovery by Utsumi. In Ybarra v. Wassenmiller, 206 Neb. 164, 171, 291 N.W.2d 725, 729 (1980), we said: "`One who is capable of understanding and discretion, and who fails to exercise ordinary care and prudence to avoid obvious dangers, is negligent or contributorily negligent.' " And, in Rodgers v. Chimney Rock P.P. Dist., 216 Neb. 666, 670, 345 N.W.2d 12, 15 (1984), we said: "One who is capable of understanding and discretion, such as the plaintiff in this case, and who fails to exercise ordinary care and prudence to avoid defects and dangers which are open and obvious is negligent or contributorily negligent." We further said in Rodgers, supra at 669-70, 345 N.W.2d at 15: "`To constitute want of due care on his part it is not required that he should have anticipated the exact risk which occurred or that the peril was a deadly one; it is sufficient that he placed himself in a position of a known danger where there was no need for him to be or that he knew or should have known that substantial injury was likely to result from his acts.'" [Citation omitted.]
. . . .
... "`One who knows of a dangerous condition, appreciates its dangerous nature, and deliberately exposes himself to the danger assumes the risk of injury from it.'"
Utsumi was not required to pursue the robber nor to take such action to protect his life. While he might not have known that the robber would shoot him in the leg, he had to have understood that by pursuing a fleeing armed robber he was placing himself in a position of a known danger where there was no need for him to be. Having voluntarily chosen to be a vigilante, he voluntarily exposed himself to danger and therefore was either contributorily negligent or assumed the risk and, in either case, is barred from recovery.
*106 Under either the theory that Utsumi knew the robber had a gun and was therefore contributorily negligent in pursuing him or the theory that as a reasonable person Utsumi had to know that by pursuing a fleeing robber, armed or not, he was exposing himself to danger, he is barred from recovery. In Sandberg v. Hoogensen, 201 Neb. 190, 197-99, 266 N.W.2d 745, 750 (1978), we said:
"It may be said that contributory negligence involves the notion of some fault or breach of duty on the part of the one charged therewith, or a failure to use such care for his safety as an ordinary prudent person would have used under the same or similar circumstances. On the other hand, under the assumption of risk, even though the risk be obvious, the person may be free from any suggestion of fault or negligence on his part...."
. . . .
... "The defense of assumption of risk is not inconsistent with the defense of contributory negligence. It is essential to the defense of contributory negligence that negligence of the plaintiff be a proximate cause or a proximately contributory cause of the injury while assumption of risk is a defense when one voluntarily exposes himself to the injury, although it plays no part in causing the injury."
Consistent with those notions, no matter how we view the allegations of plaintiff's petition, the one fact that is clear is that Utsumi voluntarily pursued a robber when he was under no obligation to do so. On that set of facts, one can reach no other conclusion than that he was either contributorily negligent sufficient to bar his recovery or that he assumed the risk and is likewise barred from recovery. The district court, therefore, was correct in granting the motion for summary judgment in favor of Todd.
The judgment is affirmed in all respects.
AFFIRMED.
