CBSE Class 12 Informatics Practices Question 107 of 147

Plotting with Pyplot — Question 7

Back to all questions
7
Question

Question 7

What will happen if you use legend() without providing any label for the data series being plotted ?

Answer

Using legend() function without labels results in default labels (e.g., "line 1," "line 2"). This can confuse viewers as it lacks meaningful information about the data series being plotted.