With eight flat cars of material needed for each mile of track laid, logistics were a nightmare, especially for the Central Pacific, which had to bring in every rail, spike, and locomotive 15,000 miles around the Cape Horn (and later a case study to justify the building of the Panama Canal).