plt.plot(np.arange(1000), np.arange(1000), label = "y = x")
plt.plot(np.arange(1000), 2*np.arange(1000), label = "y = 2x")
plt.legend()
plt.show()
How can I modify it to write the labels on the line instead on the legend?
plt.plot(np.arange(1000), np.arange(1000), label = "y = x")
plt.plot(np.arange(1000), 2*np.arange(1000), label = "y = 2x")
plt.legend()
plt.show()
How can I modify it to write the labels on the line instead on the legend?