The plaintiff, never having been licensed either under R. L. c. 103, or the St. of 1909, c. 536, as a master or journeyman plumber, the defendant contends, that, even if a permit was obtained from the city and the work was performed by licensed plumbers and accepted by the inspector of plumbing, yet the statute has been violated and the contract in question therefore is void. The contract has been executed, and, if the consideration is single and any part is tainted with illegality there can be no recovery. Kennedy v. Welch, 196 Mass. 592, 596.
What were its terms? The “estimate” given for the work included both labor and materials. But an estimated price may exceed or fall below the actual expenditure. It is merely an opinion and not the equivalent of an amount mutually agreed upon for which the contractor engages to perform the work. The declaration being on an account annexed, no reason appears why the plaintiff cannot recover for materials furnished. Jones v. Ilsley, 1 Allen, 273. Dean v. Emerson, 102 Mass. 480. Whitcomb v. Boston Dairy Co. 218 Mass. 24.
A more difficult question is whether the action can be main*36tained on the items for labor. The statute is to be read as a whole to ascertain the legislative purpose, and, unless it is necessary to hold the contract void in order to accomplish that purpose, the inference is that the statute was not intended to be prohibitory of the contract. Bowditch v. New England Mutual Life Ins. Co. 141 Mass. 292. Gaston v. Gordon, 208 Mass. 265. Pangborn v. Westlake, 36 Iowa, 546. Pratt v. Short, 79 N. Y. 437, 445. Bank of the United States v. Owens, 2 Pet. 527, 539. Harris v. Runnels, 12 How. 79, 84.
It relates to the supervision of plumbing, and full provisions are made for the examination, licensing and registration of master and journeyman plumbers, and the approval of their work by an inspector. Its primary object is the conservation of the public health from the deleterious effects which experience has shown arise from unsanitary and insufficient plumbing work due to the lack of technical knowledge and skill of those who perform it. The penalty found in St. 1909, c. 536, § 10, makes every person engaged in the business of plumbing as a master plumber, or working at the business as a journeyman plumber without being registered or licensed as required by the act, guilty of a misdemeanor punishable by fine. And by § 9 a “master or employing plumber” is defined as meaning “a plumber having a regular place of business and who himself, or by journeyman plumbers in his employ, performs plumbing work.”
But the plaintiff did not hold himself out, or carry on business, or contract with the defendant as a master plumber. If the contract is viewed as a whole he undertook to provide not only labor but materials, and the analysis of the defendant’s position must go to the extent of saying, that no valid contract for the performance of such work can be made unless the contractor himself has been duly licensed and registered as a master plumber. It would include a contractor engaged in the general business of building or repairing houses or other structures including the plumbing work, either by the day or for a round stun, and who in performance of this part of his contracts complies with the statutory requirements — a prohibition which we are not inclined to read into the statute, which does not expressly, or by implication because of the penalty, declare that such contracts shall be void as in Nourse v. Pope, 13 Allen, 87, *37and White v. Buss, 3 Cush. 448, 450. See also Faneuil Hall Bank v. Bank of Brighton, 16 Gray, 534, 538, 539, 541.
The judge to whom the case was submitted on an agreed statement of facts with power to draw inferences of fact, having been warranted in finding that the contract could be enforced, the exceptions must be overruled.
So ordered.