Growing up in conservative Madras (now Chennai), Indra Krishnamurthy (later Nooyi) and her older sister, Chandrika, were often assigned an unusual task by their mother Shantha.

“Every night at the dinner table, my mother would ask us to write a speech about what we would do if we were president, chief minister, or prime minister – every day would be a different world leader she’d ask us to play,” Nooyi recalled at an event decades later. “At the end of dinner, we had to give the speech, and she had to decide who she was going to vote for.”

The practice, she explained in 2015, turned out to be a formative experience, teaching both girls to dream big and giving them the confidence to become whoever they wanted, despite their conservative Tamil Brahmin backgrounds.

For Chandrika, that would mean becoming a partner at McKinsey, then a bank turnaround consultant, and then a Grammy-nominated musician.

Nooyi rose to the top of the American multinational giant PepsiCo, which she has led as CEO since 2006. On Monday, she announced she would be stepping down as the company’s first foreign-born and first female CEO on October 3. During her time at the helm, she established herself as one of the most powerful Indian-origin women in the male-dominated world of American business.

Breaking barriers

Indra Nooyi was born into a middle-class Chennai family on October 28, 1955.

Her father worked for the government-run State Bank of Hyderabad; her mother, a driven housewife, pushed the children to get the best grades. But she also stressed the importance of finding a good husband at an early age. After all, in most Indian households, being a wife and a mother was considered the most important job for all young women.

After studying at the city’s Holy Angels Anglo Indian Higher Secondary School, Nooyi attended the Madras Christian College, where she played guitar in a band, excelled at cricket, and eventually graduated with a bachelor’s degree in physics, chemistry, and mathematics in 1974. And at a time when few women studied business, she then got admission to the fiercely competitive Indian Institute of Management Calcutta.

“Hundreds of thousands of kids wrote the exam. 150 kids went to Ahmedabad and 100 kids went to Calcutta. Very few women were admitted, so I was motivated to break that barrier if nothing else,” she said in an interview with Poets & Quants last year.

After graduating, she worked at Mettur Beardsell and then Johnson & Johnson in Mumbai, where she helped launch the Stayfree brand of sanitary napkins. Then, Nooyi decided she wanted to study further and managed to get a scholarship to attend Yale. But an unmarried Indian woman going abroad was still a scandalous prospect at the time. Though her parents hadn’t stopped her from applying to colleges, they didn’t expect that she would get the financial aid that could make the prospect a reality.

At the Forbes Women’s Summit earlier this year, Nooyi said:

“My parents were so sure I wouldn’t get any scholarship money [that] they said ‘of course you can go.’ And then when the loan money came by they were in sort of a dilemma, how do we send this young girl off to the states, who’s unmarried. Because once she goes unmarried, she’s not marriageable at all. Nobody will marry her because she’s now gone alone to the States. So there was a big family meeting, everybody got together: Should we send her or not. I was going [anyway]!”

Her mother wanted to get her married first, but her family eventually decided to let her go. In 1978, still unmarried, she moved to the US with $500 in her pocket.

Working odd jobs to make ends meet, including as a receptionist, Nooyi managed to graduate with a master’s degree in public and private management from the Yale School of Management in 1980. Soon after, at the age of 25, she married Raj Nooyi, now president at AmSoft Systems.

Work life

Armed with a masters degree, Nooyi kick-started what would become a dazzling career spanning consulting, corporate planning, and a chief financial officer role.

In 1980, she joined the Boston Consulting Group, where she spent six years working on international corporate strategy projects across consumer goods and chemical companies. After this, she moved to mobility company Motorola in 1986 as a business development executive responsible for its automotive and industrial electronic group. In 1990, Nooyi joined Swiss industrial goods company Asea Brown Boveri where she was part of the management team.

It was in 1994 that Nooyi moved to PepsiCo as senior vice-president for strategic planning, starting off a 24 year-long career at the American food and beverage giant.

She rose through the ranks to become a senior vice-president and then the CFO. During her tenure, Nooyi negotiated the company’s acquisition of Tropicana (1998) and Quaker Oats (2000), which helped PepsiCo establish itself in the growing healthy foods segment. These acquisitions paved her way to the title of president and CFO in 2001. She also led the spin-off of PepsiCo’s fast-food business under the YUM! Brands into a separately listed entity in 1997.

By 2006, PepsiCo was ready to announce her as head, making her its first female chief ever.

Over the years, Nooyi’s top job earned her coveted titles such as “America’s second most powerful businesswoman,” even as she consistently ranked among the top American female CEOs.

Her journey at PepsiCo, though, has been far from smooth.

By the mid-2000s, soda consumption in America – the world’s largest market for the product – began declining rapidly. Consumer and activist concerns grew amid rising obesity levels, pushing soda sales down by 20% in the US between 2007 and 2013. What followed was a loss of market share, job cuts, and curtailed investments in marketing and research and development.

Amid growing pressure from shareholders and shifting consumer preferences, Nooyi took a tough call to veer PepsiCo into a different direction. This would essentially pivot the company into healthier products while reviving soda sales and finding better alternatives for sugary drinks.

By 2014-15, Nooyi’s efforts were beginning to show signs of success as the company’s snacking business in North America performed well. Despite speed bumps, PepsiCo has continued its journey towards launching healthier products, investing in packaging and bolstering investments in key markets, including India.

Today, PepsiCo is well on the path towards recovery. While its core beverages business in America is yet to see a full revival, its snacking business, comprising of Lays and Doritos, is doing well globally.

Now, after over two decades, it’s Nooyi’s time to pass the baton. As her exit statement read, “Being a CEO requires strong legs and I feel like I ran two legs of a relay race and I want somebody else with nice strong legs and sharp eyes to come and lead this company.”

Nooyi’s next move is yet to be announced.

This article first appeared on Quartz.