BuildlyBuildly
DashboardExercisesProfileHelp
Data Science/Module 4: Data Visualization/Matplotlib Basics2/3
Exercise·7 min·10 XP

Plot a Revenue Trend

Context. Six months of revenue numbers are sitting in a list. A line chart makes the trend obvious at a glance.

Your task. Write make_line_chart(months, revenue) that creates a figure, draws revenue over months as a line, and returns the axes.

Example. fig, ax = plt.subplots() gives you a figure and axes; the line goes on the axes.

Notes. Return ax, not fig. One line only — don't add extra plots.

Next
Bar Chart of Category Sales