(after stating the facts as above). It is evident that the bank under its contract was obligated to maintain, subject to demand, the county deposits, and to pay interest thereon monthly, on demand, upon the daily average balances, per month. The payment of interest on such daily balances was a mere incident to the main obligation to maintain these deposits of the county subject to demand. When the bank became insolvent, these demand deposits, including the accrued interest, no longer could be paid upon demand. There then arose a breach of the bond given by the defendant to the plaintiff, to wit, the engagement to insure the maintenance of such demand funds with the interest specified. In no manner can this engagement be termed a contract to pay interest at 3 per cent per annum upon demand deposits when they were not subject to be so termed. The contract rate concerns the payment of interest upon the fluctuating balance of demand deposits. A distinction may be drawn between a contract to pay money *231only and tbe obligation to maintain demand funds and tbe payment of interest thereupon, pursuant to a fluctuating balance, while the same are maintained as demand funds. After they ceased to be available as demand deposits, the contract rate for the payment of interest upon a fluctuating balance did not then apply. See Central Bank & Trust Corp. v. State, 139 Ga. 54, 76 S. E. 589; Fidelity & D. Co. v. Wilkinson County, 109 Miss. 879, 69 So. 869; 18 C. J. 594. In a manner, the defendant was an insurer of this obligation on the part of the bank. Long v. American Surety Co. 23 N. D. 492, 504, 137 N. W. 41. The legal rate of interest is allowable by way of compensation as damages for breach of the contract. First Nat. Bank v. State Bank, 15 N. D. 594, 613, 109 N. W. 61; Comp. Laws 1913, §§ 7141, 7142. See 22 Cyc. 1523. The plaintiff was entitled to recover the legal rate of interest from the time of the demand made upon the surety. Dickinson v. White, 25 N. D. 523, 538, 49 L.R.A.(N.S.) 362, 143 N. W. 754. See note in Ann. Cas. 1916B, 1236, 1244. Until July 1, 1915, the legal rate of interest was 7 per cent per annum. Comp. Laws 1913, § 6073. Since that time the legal rate of interest has been 6 per cent per annum. Laws 1915, chap. 176. The trial court allowed interest at the rate of 7 per cent per annum from the time of the demand. In this regard we are of the opinion that the trial court erred. The plaintiff seeks to recover interest as damages, and not by reason of the contract. It is entitled accordingly to recover such legal interest pursuant to the statutory rate covering the respective periods involved, namely, interest at 7 per cent per annum upon the principal demand until July 1, 1915, and thereafter at 6 per cent per annum. See 22 Cyc. 1523; O’Brien v. Young, 95 N. Y. 428, 47 Am. Rep. 64. It is ordered that the judgment be modified accordingly, and, as so modified, that it be affirmed. Neither party will recover costs upon this appeal.
Eobinson, Oh. J., and Christianson and Birdzell, JJ. concur.