Restaurant: How long can prepped food (cut vegetables, garnishes, etc) be stored before it has to be thrown out?
Many chefs and restaurants follow food storage guidelines obsessively, at least in part because they're required to. Using ingredients that have been stored longer than considered safe can result in customers getting sick, in which case they probably won't return, they'll tell their friends or use social media to spread the word, and they may take legal action if they got really sick. If a health inspector catches such violations, they won't be happy either, and they have a number of potential penalties to impose.

Food cost is on par with labor as being one of the largest costs of running a food service business. I've always heard the "rule of thirds" as a guideline for operating costs in a restaurant setting: 1/3 food cost, 1/3 labor cost, and 1/3 profit (which is not always pure profit and may involve reinvesting back to the business). Industry benchmarks bear this out as well.

My point with all of this is that chefs have two strong, competing incentives:


Do not waste food, because it's expensive in the short term!
Do not serve bad or spoiled food, because it's expensive in the long term!


Obviously there are bad chefs out there who simply don't care. They may not be invested in the business, poorly trained, or just checked out. And many of us have seen reality TV exposes that show how awful some kitchens are.

But, the good chefs that I've worked for and with have a couple different approaches to using up prepped ingredients and avoid throwing things out:


Good labeling and storage. This is really fundamental anyway if you want to ensure that you know how old everything is. Some ingredients (blanched or hearty vegetables) will easily keep for a day or two after being prepped if they're kept cold. All you need do is store them correctly (which depends on the exact food) and use some easy, reliable labeling system to keep things straight in the fridge. 
Recycle them into a different dish tomorrow. Lots of restaurants have specials or rotating items. If I shelled a bunch of beautiful fresh peas for a risotto on the dinner menu and I simply don't sell many, I can turn the extra peas into a delicious soup tomorrow. If I'm smart, I'll also use up some of the ham that I diced for a different dish, and the vegetable stock that I use everywhere and have to make more of anyway. On which note:
Turn them into basic or pantry ingredients. Some chefs are really good at this. There are certain things that you can use everywhere: stocks, breadcrumbs, etc. And they aren't necessarily picky about their base ingredients being in prime quality. I might make vegetable stock every couple of days using whatever pre-prepped vegetables I've got on hand, supplemented as needed with fresh (also an excellent way to use up odds and ends that can't be served on their own, like celery stalk bottoms). I might take a surplus of julienned carrots that would have been garnish and pickle them for later use. I could take fresh herbs that are starting to wilt and use those in a marinade for meat. This is a really defining quality for a great chef for me: cleverness with a broad range of ingredients and preparations, and a willingness to experiment. After all, if those pickled carrots don't work out, I would have had to throw them anyway.
Compost them. Not feasible for everybody, but growing their own food is something of a trend and obsession for certain chefs. Rather than having things go to waste I can do what a smart home gardener would, and turn my sad wilted vegetables into healthy compost for my rooftop herb garden.


Most chefs who do these sort of things are also very good about monitoring how much they sell and doing their best not to order or prep more than they need, so they don't have tons of waste in the first place. Chefs who aren't as passionate simply wind up throwing more out. This leads to the curious assertion (but I've seen it quoted from Gordon Ramsay as well) that you can learn a lot about a chef by going out back and checking the dumpster.

Oh, and since your question asks specifically about line and prep cooks: ideally, they are doing exactly what the head chef tells them to. That's basic kitchen discipline. If they go off on their own and prep three times more potatoes than they were told to, they won't be prepping potatoes or anything else for too much longer.