This is an action brought by the county of Brown to recover from the city of Aberdeen one-third of the moneys collected by said city for license issued by it for the sale of intoxicating liquors within the corporate limits of said city. As will hereinafter be seen, this suit is based on Sections 1 and 2 of “An act to amend an act to incorporate the city of Aberdeen, in the territory of Dakota, ” passed and approved March 11, 1885. The Sections 1 and 2 of the act referred to supra are as follows:
“Section 1. The mayor and city council of the city of Aberdeen, in the territory of Dakota, shall have the exclusive right, under the charter of said city of Aberdeen, to license persons to sell and vend intoxicating liquors within the limits of *405said city; which license shall not be granted for a less snm than five hundred dollars, nor more than one thousand dollars, for each year, and the same shall be in lieu of all license for the sale of such intoxicating liquors under the general law of the Territory of Dakota.
Sec. 2. The mayor and city council of the city of Aberdeen shall have the power to vacate or change the corporate limits of the city of Aberdeen, that all or any part of said city, now lying in section twenty-three, township one hundred and twenty-three, range sixty-four, may be excluded from within the corporate limits of said city; provided, that one third of all money collected for license for the sale of malt, vinous, or spirituous liquors shall be paid into the county treasury within thirty days after the collection thereof by the treasurer of said city. ”
There are two or three other sections of this act, not necessary to be quoted here, as they have no bearing on the question under consideration.
The complaint among other things, alleges that plaintiff and defendant are corporations; that defendant, pursuant toan ordinance duly passed by virtue of the act supra, granted licenses for the sale of intoxicating liquors within its corporate limits to divers and sundry persons, and by reason thereof collected the sum of $4,361.38, more than 30 days prior to the institution of this action; * * * that plaintiff had made demand of defendant for the sum of $1,453.79, being one-third of the amount collected by the defendant as aforesaid; that the defendant refused and neglected to pay the same, or any part thereof, and it is now due and wholly unpaid; concluding with prayer for j udgment for said sum, and costs, etc. To this complaint defendant put in a general demurrer, which was overruled, and defendant, failing to answer bill, elected to stand by his demurrer. The court below ordered judgment for the amount claimed in complaint.
The case is brought here on appeal for the purpose of having the action of the district court reviewed, and the following assignment of error is presented by the defendant: (1) That *406the court erred in overruling demurrer, and rendering judgment for plaintiff; (2)the court erred in so construing said act, or in any manner so construing said act, whereby the court should find that the defendant was liable to pay one third of the license so collected to the plaintiff; (3) that the complaint does not show that the defendant excluded from its corporate limits the land described in Section 2 of said act as a condition precedent to its being entitled to receive or recover as stated in the complaint.
It is evident that the only question presented for consideration by this court is the proper construction to be given to the proviso appended to Section 2 of the act to amend the charter of the city of Aberdeen. It is true, that appellant ostensibly assigns three errors or reasons why the judgment of the district court should be reversed; but, when stripped of all unnecessary verbiage, it really amounts to but one, and that is the construction of the proviso aforesaid.
Counsel for appellant contends that the complaint was not good because it failed to allege that his client had excluded from its limits the land described in Section 2 of said act. If this is the correct view of the matter, there can be no doubt that the district court ought to have sustained the demurrer, and therefore the case should be reversed. It is also contended by counsel for appellant, and not without some force or plausibility, that the proviso should be construed with reference to the matter contained in Section 2 alone, of which it is apparently a part, and therefore cannot, within sound rules of construction, be applied or transferred to Section 1 of said act. As a general proposition,'this may be true, and we would not hesitate to adopt it in this case if it could be done without defeating the clear intention of the legislature, and rendering the act unreasonable, and in a measure absurd., A proviso is not always to be held to apply to the section immediately preceding it, but is frequently construed as modifying other sections of the statute. U. S. v. Babbitt, 1 Black U. S. 55; Mayor, etc., v. Magruder, 34 Md. 381.
Can this proviso be made effective when confined to or con*407strued with reference to Section 2 alone? We think not, for it has no reference or application to the legislation or subject-matter embraced within the section in question, unless we hold that the legislature intended to grant the city of Aberdeen the power to change its corporate limits, and at the same time impose a penalty in th§ nature of a forfeiture of one-third of its revenue received from licenses to sell liquor whenever the city, through its mayor and council, should choose to exercise that power. This certainly is not a sensible or a reasonable view of the matter. Was there any harm or injury to result to the county by the change of the boundary of said city? None that we can see. But would it not rather result in a diminution of the financial ability of the city, for the reason that it could no longer collect taxes on the property embraced therein, or from citizens living on the land thus excluded? Then, why should we conclude that the legislature intended to impose this forfeiture on the city, or confer this bounty on the county, under such circumstances? It iá plain that the legislature intended, and so directed, that one-third of this license money should be paid within thirty days after the collection thereof by the city. This could not be done unless the city exercised the power of changing its boundary within thirty days after it collected its first money for license. This it has not done, and may never do for years, or at all. Hence, if we give construction to the proviso contended for by counsel for appellant, that part of it which directs the money to be paid within thirty days after collection could not now possibly be complied with, and, if hereafter the city should exclude the land aforesaid from its limits, the county would only be entitled to receive one-third of license money collected after changing the boundary aforesaid, unless we should hold the act retroactive in its effect. To do this would result in compelling the city to pay to the county moneys that it had collected for an indefinite and unlimited time that might elapse previous to the exclusion of the land aforesaid, and which had become intermingled with the general city affairs, or expended in due course thereof. It seems to us that a con*408struction that would result in this state of affairs would be unreasonable, not to say absurd.
It is a well settled doctrine that, in giving constructiun to an ambiguous or doubtful statute, that courts will look at its effects or consequences, and they will discard any construction that leads to unreasonable, foolish, or absurd consequences, but will rather, adopting the language of Lord Hale, ' quoted approvingly by the supreme court of the United States, “be curious and subtle to invent reasons and means in order to give force and effect to the clear intent to the law-making power.” Bosely v. Mattingly, 14 B. Mon. Ky. 89; Oates v. National Bank, 10 Ott. 244.
Again, in construing statutes, we should seek to find the intention of the legislature, and, when the intention is discovered, it is the duty of courts to so construe it as to enforce and make it effective, and not defeat it by a too rigid adherence to the letter thereof, or'to technical rules of construction. Wilkinson v. Leland, 2 Pet. 627; People v. Utica Ins. Co., 15 Johns. 858; Sedg. St. & Cons. Law, 196.
We are of the opinion that the legislature intended by this act that there should be collected a revenue on sales of liquor within the corporate limits of the city of Aberdeen; that said city should have the exclusive right to grant license for the sale thereof, at a rate not less than $500 nor more than $1,000 for each year, in derogation of all general laws of the territory on the same subject. But by reason of this extraordinary privilege, and from the fact that this act repeals the general law, which gave to said county the right to grant license for the sale of liquor within the limits of said city, and collect a tax therefor, it intended that the county should not be deprived of this source of revenue, but rather intended to simplify the mode of collection by confining it to the machinery of the city, government, and that said city should pay one-third of all revenue thus collected into the treasury of the county. We are driven to this conclusion not only from the act itself, but from antecedent and contemporaneous legislation regarding the same' subject-matter. See Sess. Acts 1879, § 7, p. 89, which the courts will judicially *409notice for this purpose. Sedg. St. & Const. Law, 202, 203. Having discovered the intention of the framers of the law, it should be followed with reason and discretion, though seemingly contrary to the letter of the statute. People v. Utica Ins. Co. supra.
Again, in the construction of the statute, every part of it must bS reviewed in connection wit a the whole, so as to make all of its parts harmonize and to give an intelligent effect to each and every part thereof. Taking this whole statute together and reviewing it for the purpose, and with the desire to give to it a reasonable and sensible construction, and to get at the clear intention of its makers, and to give every part thereof full force and effect, we are irresistibly led to the conclusion that the proviso under discussion was intended by the legislature to modify and limit Section 1 of said act. As thus applied, its provisions are opposite, and serve to harmonize the legislation embraced in said action, while it is plain, even to i^ie unlegal mind, that it has no natural reference or relation to the subject matter of Section 2, and cannot be held to apply or modify said section without rendering the entire act, or at least these two sections, uncertain, incongruous, if not incapable of being intelligently and effectively enforced. The entire act should be so construed that it. shall be rational, harmonious, and all of its parts made to speak sense rather than absurdity. To do this, this proviso must be construed with reference to Section 1 of said act, or treated as a separate section, modifying and limiting the entire amendment of which it is part. But we are rather of the opinion that should be applied, as above stated, to Section 1, and that it ought to have been and was so intended by the legislature to be appended to said section, and by reason of the want of skill on the part of the' draughtsman, or through the mistake of the engrossing clerk, it became attached to Section 2 instead. However this may be, we are clear that the legislature intended by the act in question to give to the city of Aberdeen the exclusive right to fix the license for the sale of intoxicating liquors within its corporate limits, and to collect the same, provided it paid one-third of the money *410thus collected into the treasury of the county; and. this, without regard as to whether said city should vacate-or change its boundary as provided in Section 2 of said act or not. Hence we find no error committed by the district court, and the judgment is in all things affirmed.
All of the justices concurring.-