Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Apprendre Task: Finding Total Sales Per Drink | Basics of Dataframes
Pandas: First Steps
course content

Contenu du cours

Pandas: First Steps

Pandas: First Steps

1. Getting Started
2. Basics of Dataframes

book
Task: Finding Total Sales Per Drink

Tâche

Swipe to start coding

At Café Pandasia, the manager wants to track the total sales for each coffee drink

You’ve been given a DataFrame that tracks the sales of three drinks across three days (Monday to Wednesday), and now you need to add a new column called Total Sales to the DataFrame.

  • Add a new column called Total Sales to df.
  • Total Sales should contain the sum of the sales from Monday to Wednesday for each drink.

Solution

Switch to desktopPassez à un bureau pour une pratique réelleContinuez d'où vous êtes en utilisant l'une des options ci-dessous
Tout était clair ?

Comment pouvons-nous l'améliorer ?

Merci pour vos commentaires !

Section 2. Chapitre 6
toggle bottom row

book
Task: Finding Total Sales Per Drink

Tâche

Swipe to start coding

At Café Pandasia, the manager wants to track the total sales for each coffee drink

You’ve been given a DataFrame that tracks the sales of three drinks across three days (Monday to Wednesday), and now you need to add a new column called Total Sales to the DataFrame.

  • Add a new column called Total Sales to df.
  • Total Sales should contain the sum of the sales from Monday to Wednesday for each drink.

Solution

Switch to desktopPassez à un bureau pour une pratique réelleContinuez d'où vous êtes en utilisant l'une des options ci-dessous
Tout était clair ?

Comment pouvons-nous l'améliorer ?

Merci pour vos commentaires !

Section 2. Chapitre 6
Switch to desktopPassez à un bureau pour une pratique réelleContinuez d'où vous êtes en utilisant l'une des options ci-dessous
Nous sommes désolés de vous informer que quelque chose s'est mal passé. Qu'est-il arrivé ?
some-alt