Calculate Average Using np.mean()
📖 Scenario: You work in a small bakery. You have daily sales numbers for a week. You want to find the average sales to understand how well the bakery is doing.
🎯 Goal: Calculate the average daily sales using np.mean() from the sales data.
📋 What You'll Learn
Create a numpy array called
sales with the exact daily sales numbersCreate a variable called
average_sales to store the averageUse
np.mean() to calculate the average of salesPrint the value of
average_sales💡 Why This Matters
🌍 Real World
Calculating averages is common in business to understand typical performance, like average sales per day.
💼 Career
Data analysts and scientists often use averages to summarize data and find trends.
Progress0 / 4 steps