In this segment from the Market Foolery podcast, host Chris Hill is joined by senior analyst Jason Moser to discuss the pending departure of longtime PepsiCo (NASDAQ:PEP) CEO Indra Nooyi. She led the company through a diversification into somewhat healthier fare, to complement its sodas and salty snacks.

Nooyi joins a fairly long list of major packaged-food company chiefs to head for the door in the past couple of years, a reflection of the difficult environment that the entire segment is currently operating in. But the Fools have nothing but praise for her leadership and the condition in which she's leaving the company.

A full transcript follows the video.

This video was recorded on Aug. 6, 2018.

Chris Hill: We have to start with the news fairy news, and that is, Pepsi announced CEO Indra Nooyi is stepping down in October. This will mark 12 years that Nooyi has been CEO of Pepsi. She's going to stay on as chairman of the board of directors through early 2019. Ramon Laguarta is going to be promoted up to CEO. When you think about her track record, 12 years, the thing that struck me when I was digging around this morning is how closely shares of Pepsi tracked the S&P 500 while she was CEO.

Jason Moser: I'm not trying to give the incoming management any sort of black marks or challenge here, but man, I would not want to be filling her shoes. She set the bar really high. To me, this is a really big loss for Pepsi. I think it's hard to overstate that. And a lot of that goes back to that track record you mentioned. For the longest time, PepsiCo more or less tracked the S&P. It's only the last couple of years where we've seen a little bit of a drop-off in the performance.

She's obviously hitting a point in her life where, maybe, she wants to go do other things, or focus on family, or other worldly issues. I think she probably looked at the tasks that are ahead for this company, and the industry in general, and thought, "I've done what I can do here. I don't want to get stuck in this multi-year headwinds battle that I may not be able to ultimately win anyways," or at least make some meaningful impact that she hasn't already done for the company.

The company itself is in very good condition, it's in good shape. I love the fact, we talk about it all the time, that they have that diversity in the salty snacks division with Frito-Lay. That goes all the way back to 1965 or something, when that all came about. To me, the loss of Nooyi as a leader, beyond just what she's done with this company, she's a leader in every sense of the word. Very openly communicative, really praises employees, believes in her company playing a bigger role in the world than just making profits for Wall Street on a quarterly basis. A leader in every sense of the word. We talk a lot about conscious capitalism, and I think she has a lot of the qualities that fit in that mold.

Hill: You mention Frito-Lay. When I think about her tenure as CEO, one of the things I thought when I saw this news that she was stepping down was about, at least a couple of times during her tenure as CEO, activist investors coming forward, trying to push her to make a splashy spin-off, saying, "Look, spin off Frito-Lay and focus on Beverage." I think there was also someone who came in and said, "Spin off the Beverage, focus on Frito-Lay." To your point about her leadership, she said, "No. We are a stronger company with these divisions working together."

To your point how about the recent performance of Pepsi, but also this industry ... here's a short list of companies dealing in food and beverages who have gotten new leadership over the last two years: Coca-Cola, Mondelez, Kellogg's, Campbell Soup, Hain Celestial, General Mills, and Smucker's. I don't think that's any accident. This is starting to be a much more challenging industry than it used to be. To your point, I think she just said, "You know what? I've had a heck of a good run and I'm riding off into the sunset." Good for her.

Moser: She's 62 years old, I can't blame her at all. If she sticks around ... she's more less gearing up for at least another five years of trying to deal with a market where the competitive forces are only growing, consolidation is becoming more and more a factor, prices continue to get pushed down. The profitability for businesses like these just becomes more and more difficult as time goes on. Obviously, we know the challenges that soda faces. Well, Pepsi is really well-known for soda.

Now, thankfully for them, they have a number of different ways to make their money. I think that's ultimately what should leave investors in PepsiCo today feeling good about the future. I think the company is set up to continue to succeed. But it's absolutely going to be a very difficult market going forward. If you're looking for that top five list of stocks where you want to put new money, even if Nooyi is still at PepsiCo, I don't know that I put PepsiCo on that list ultimately because of the market itself. It's not a company thing, it's a market thing.

Hill: Interesting to me, Ramon Laguarta will become the sixth CEO in company history -- every CEO has been promoted from within.

Moser: That's good. We like to see that. It gives you an understanding that they see the value in having someone who's already very familiar with the company, and someone who's been able to at least work under Ms. Nooyi's tutelage. You just can't say enough good things about her. We'd be so much better off if we had more leaders like her around the world.