COBB, C. J.
The plaintiff filed in the district court of Douglas county his petition, as follows: “Now comes the said plaintiff, and, complaining of the said defendant, says that on or about the 15th day of October, 1885, this plaintiff contracted and agreed to construct and finish all the grading work on the line of the Fremont, Elkhorn & Missouri Valley Railroad, from station numbered 10,644 to station numbered 10,699, as the railroad of said company was then located, being a distance of one mile, by which contract and agreement this plaintiff agreed to construct the grading work on said portion of said road, and the said defendant agreed to pay this plaintiff therefor as follows, to-wit: For solid rock excavation, the sum of ninety cents per cubic yard; for loose rock excavation, forty-five cents per cubic yard; for earth work, the sum of sixteen cents per cubic yard;--for each and every cubic yard of excavation and embankment in the construction of the part of said line of railroad hereinbefore mentioned, a copy of which contract is hereto attached and marked ‘Exhibit A.’ Plaintiff further says that in pursuance of said agreement and contract he did, on or about said 15th day of October, 1885, commence the construction of said railroad under and in pursuance of the terms of said contract, and continued the construction thereof until about the 2d day of February, 1886, at which time the said defendant wrongfully, and without any valid reason therefor, required this plaintiff to deliver the exclusive possession of the work then being constructed, and the unfinished portion of the work included in said contract, to him, the said defendant, together with all the teams, wagons, plows, scrapers, shovcls, and other material and tools then on the said work, the property of plaintiff, as also the men, teams, and tools on said work then in the employ of and hired by this plaintiff; and the said defendant, after so wrongfully taking the possession thereof, continued said work for plaintiff with his tools, machinery, men, and other property aforesaid until the entire work under the provision of said contract was finished. Plaintiff further says that in the construction of that part of said railroad included in said contract, and under the provisions thereof, this plaintiff, while prosecuting said work, and defendant while continuing said work as aforesaid for plaintiff, excavated and put in embankments as per the provision of said contract about fifty-seven thousand (57,000) cubic yards of earth, for which defendant agreed to pay the sum of sixteen cents per cubic yard, amounting to the sum of $9,120; that in the further construction of said work this plaintiff and said defendant, in the manner aforesaid, excavated in the construction of said railroad about three thousand cubic yards of loose rock under the provisions of said contract, for which defendant agreed to pay the plaintiff forty-five cents per cubic yard, amounting to the sum of $1,350; that in the further prosecution and construction of said road this plaintiff and the defendant, in the manner aforesaid, excavated about thirty-three thousand seven hundred and sixty (33,760) cubic yards of solid rock under the provisions of said contract, for which defendant agreed to pay this plaintiff ninety (90) cents per cubic yard, amounting to the sum of thirty thousand three hundred and eighty-four dollars ($30,384;) that the defendant has paid thereon the sum of twenty-five thousand ($25,000) dollars, and no more; and that there is now due from said defendant to this plaintiff, on the construction of said work, the sum of fifteen thousand eight hundred and fifty-four dollars ($15,854.) For a second cause of action against defendant plaintiff says that at the time of the taking possession of the work, tools, and other property, as set forth in the first cause of action herein, to-wit, on or about the 2d day of February, 1886, said defendant then and there took the possession of the following described chattel property, to-wit: A large number of tools, consisting of scrapers, shovels, drills, mattocks, picks, sledges, crowbars, (the number of each kind thereof plaintiff is at the time of filing of this petition unable to state,) of the value of three hundred dollars, ($300,) this plaintiff being the owner thereof, and unlawfully and wrongfully converted them to their own use, to the damage of the plaintiff in the sum of three hundred dollars ($300.) Wherefore the plaintiff prays judgment against the defendant for the sum of sixteen thousand one hundred fifty-four dollars, ($16,154,) and interest thereon from the 1st day of May, 1886, and costs of suit.”
The defendant filed answer, as follows: “Now comes the defendant for answer to the plaintiff's petition, and says: He admits that on or about the 15th day of October, 1885, plaintiff and defendant entered into the contract referred to in plaintiff's petition, and the defendant says that plaintiff neglected and refused to prosecute the work with such forces, tools, and machinery as the engineer in charge deemed adequate to its completion within the time specified in said contract, and that on the 2d day of February, 1886, plaintiff and defendant entered into a new contract, by the terms of which the plaintiff agreed to let this defendant put a foreman on the work mentioned in said contract, who should have entire and exclusive management of the work at plaintiff's expense, including keeping pay-rolls and paying men; that in pursuance of said agreement one of defendant's foreman took charge of said work under said agreement, and with the consent of...