The respondent instituted this proceeding to compel the railway companies to construct and maintain a bridge for pedestrians over Railroad avenue at Yesler Way, in the city of Seattle.
In 1915, the city passed an ordinance establishing a route and fixing grades for the bridge. The route extended along the south side of Yesler Way from First avenue to the west line of Railroad avenue. The grade so established began at the sidewalk on First avenue and increased in elevation westerly to about thirty-two feet above Railroad avenue. In 1918, the city, by ordinance, directed the railway companies to construct this bridge at their own expense. The companies being unable to apportion the cost among themselves, *75the city, by ordinance, apportioned the cost of the main structure as follows:
The Northern Pacific Railway Company.... 42.159%
The Great Northern Railway Company..... 50.029%
The Chicago, Milwaukee & St. Paul Railway Company ......................... 3.906%
The Oregon-Washington Railroad & Navigation Company ....................... 3.906%
It also provided that the approaches to the bridge were to be paid for equally by the four railway companies.
Appellant, deeming the apportionment unjust and arbitrary, refused to comply with the ordinance. The trial court found in favor of the city and entered judgment directing a peremptory writ of mandate to issue as requested, from which this appeal is taken.
Appellant admits that the construction of the bridge is necessary.
“The city, . . . can compel these railway companies to pay such proportion of such cost as may be just, upon the equitable principle thát the presence of the railway tracks creates the dangerous situation sought to be relieved and makes the change of grade a public necessity.” Spokane v. Spokane & Inland Empire R. Co., 75 Wash. 651, 135 Pac. 636.
•Appellant contends that the cost of the máin structure and approaches should be divided between the railways in proportion to the width of their respective rights of way and not in proportion to the used rights of way as provided by the city. The portions of the rights of way not included were granted in 1908 and are not now and never have been used.
The apportionment of the cost upon the basis of the width of the respective rights of way has been sustained by judicial authority. State v. Minneapolis & *76St. L. R. Co., 39 Minn. 219, 39 N. W. 153; State ex rel. City of Duluth v. St. Paul & D. R. Co., 75 Minn. 473, 78 N. W. 87.
There is no definite rule for the apportionment of costs for either the main structure or the approaches. It has been held that where several roads create a dangerous condition, the fact that they each participate in the production of the common danger does not relieve any of them from the separate obligation to pay the entire expense of its elimination. Erie R. Co. v. Board of Public Utility Commissioners, 254 U. S. 394, 65 L. Ed. 322; Chicago, B. & Q. R. Co. v. State ex rel. Omaha, 170 U. S. 57, 42 L. Ed. 948, 954; New York & N. E. R. Co. v. Town of Bristol, 151 U. S. 556, 38 L. Ed. 269, 272; Public Service R. Co. v. Board of Public Utility Commissioners, 89 N. J. Law 24, 98 Atl. 28.
The city evidently considered that it was the used portions of the rights of way that created the danger to the public. We are unable to say that the apportionment based upon the width of the rights of way actually in use by the respective railways is arbitrary or discriminatory.
It is contended that the city should also have included a track of the Northern Pacific Company not on Railroad avenue at the main structure but passing under the main structure on Western avenue. This track of the Northern Pacific Company on Western avenue passes under the bridge with a clearance of about 20.9 feet, while the standard clearance is about twenty-three feet on Railroad avenue. The danger that the city desired to overcome was primarily upon Railroad avenue and not Western avenue, and for that reason they properly omitted this track from their consideration.
*77The city divided the cost of the approaches equally among the four railway companies. It has been held that the railroad operating next to the approach to the main structure should pay the entire expense of the approach on that side of the bridge. State v. Minneapolis & St. L. R. Co., supra. The city may have directed. each railroad to pay one-fourth of the construction of the approaches upon the theory that the approach to the main structure is as necessary to the railway occupying fifteen feet under the main structure as it is to the railway occupying fifty feet beneath the main structure. The size and the expense of the construction of the approach to the bridge is in nowise affected by the number of tracks spanned by the main structure. The city endeavored to distribute this cost according to its judgment as to what is fair, just and reasonable. We cannot say that it acted arbitrarily or capriciously. On the other hand, considering the facts in this case, we are of the opinion that the apportionment was eminently fair and just between the respective railways.
It is next contended that the city exceeded its authority in requiring the railroad companies to jointly construct and maintain the bridge and approaches, and our attention is called to the case of State ex rel. City of Duluth v. St. Paul & D. R. Co., supra, wherein the court said: *78was done in State v. Minneapolis & St. L. R. Co., supra.”
*77“We are unable to discover on what principle it can be sustained. In so far as the legal obligation to bridge the tracks is concerned, it is impossible to say that it is joint, or to see why one company should be compelled to perform the duty of another. The obligation to build, although common, is not joint, but several, except as to those tracks jointly owned by these appellants. And their several obligations should have been determined and adjusted by the court when making its findings of fact and conclusions of law, as
*78In this same case the court also said:
“No apportionment, either of cost or parts to be constructed, was made, and counsel for the city admits that the order must be construed as imposing upon each of these companies the duty of constructing the entire structure, with abutments and filled approaches.”
Appellant also cites the case of State v. Minneapolis & St. L. R. Co., 39 Minn. 219, 39 N. W. 153, wherein it is held that the obligation of each of two railway companies to construct a bridge spanning their tracks was an independent and not a joint obligation. These tracks had land intervening between them and the proceedings against the two railway companies were separate. The court said:
“These separate proceedings against the two corporations contemplated that the work thus charged upon them separately should, when performed, constitute entire and complete bridges over both.systems of tracks, with proper street approaches.”
.'The .court also said in referring to the joint obligation:
“We have spoken of the duties of these companies as being independent, and not joint. This is not to be confounded with the plan or manner of. performance, which, as respects both companies, should, for obvious reasons, be in. some sense and to some extent common, or at least similar. ”
Unless the city has authority to apportion the cost to the respective railroads it would be necessary to set apart to each of the roads certain portions of the construction of the bridge and approaches. It seems that the city council has adopted a plan whereby each should pay its just proportion rather than building a *79separate portion. Since this is one structure, we are satisfied that it is entirely proper to direct the railway companies to jointly hear the expense of its construction rather than to direct each of the railways to build certain sections.
Believing the apportionment to he just, fair and equitable, the judgment will be affirmed.
Main, C. J., Mitchell, Fullerton, and Bridges, JJ., concur. . . ■ . .