As a retiree I hit the supermarket at odd hours, including times when employees or suppliers are changing the merchandise for sale. The produce people go through the old produce and usually throw out the majority of it. The bread people check the codes on the loaves and take back a lot.
We humans have a simple rule for food: when there's a choice, take the freshest and the best looking. That simple rule means we waste a lot, because the whole marketsystem is founded on giving the consumer choices.