totally depends on the training program. I'm more of a time on my feet guy over pure mileage these days. Mostly b/c its easier with kids and a wife who also trains. She knows pretty much exactly when I'll be back. That, and I've done the distances in the past, so I don't need the mental confidence of running "x" amount of miles.
50K won't be much different than a marathon training program, from a distance perspective.
50 mile, 100k, 100 miler can all look pretty similar. For a 50 miler and a 100K, optimally, I'd probably do a 50K as a longest run, but I've done them on shorter. For the 100K i'm doing in a few weeks, the longest run I'll have done is about 21.5 miles. But that's due to having injury issues that torpedoed my training program.
100 miler, I'd optimally do a 50 miler, don't really need to go that far. 50K will work too. I've finish AT100 with no single run over 25 miles.
All of the above said, its really about how the entire training block is structured. If you run like seven or 8 20+ or a bunch of back-to-back long runs of 20/15 miles or something, then you can easily get away with a shorter longest run. Running low mileage, slogging through a 50 miler 5 weeks out and then showing up at the start of a 100 won't be as effective as a good plan with a shorter long run.
maybe you were hoping for a more straight-forward answer, but everyone and every training program is different.
then you have someone like Camille, who barely does long runs. That said, she also has the genes for it and races enough that she has a huge base to draw from. And if you read the article, she does a lot of 10-15 mile runs during the week.
https://www.trailrunnermag.com/training/camille-herron-says-skip-the-long-run/