I recall that the Reading Railroad kept an 0-6-0T for a shop goat unitl 63 or 64. A Reading fan can probably give a closer answer. The Wabash kept some 2-6-0s for a line that had a light bridge loading untill the mid 50s. The N&W kept some of their late built 0-8-0s in service right up to 1959 or 1960. As some one else has posted a lot of the major railroads started their diesel use by trying out diesel switch engines so a lot of steam switchers went to scrap early.
I can't talk about ALL railroads, but lots of them got rid of their smaller steam locos first. That was why diesel switchers were sold, way at the beginning.
The ONLY steam on the SP&S that survived after 1954 was ALL of their 4-8-4's and ALL of their 4-6-6-4's.
But staying with small steam, the SP&S still had 3 2-8-0's in 1954. Their 0-6-0's were retired in 1951-52.
Going to the mid-size, their last 2-8-2 was retired in 1954, and their last 4-6-2 in 1953.
The GN had a dead line of retired steam held until about 1960. I don't recall seeing ANY small steam in the line.
Ballparky, I would say the answer to your question would be about 1950. Or "the early fifties".
Ed
The title says it all. How late were Class 1 railroads still using small steam engines for maintenance, freight yards, etc.? I have seen pictures where a train pulled by an E or F unit shows a small steam engine in the yard someplace. Just curious.