heroking146 发表于 2020-9-13 09:20:02

Traceback (most recent call last):??用pycharm python3.8

from matplotlib import pyplot as plt
importrandom
x=range(2,62,2)
y=
plt.plot(x,y)
plt.show()


Traceback (most recent call last):????
用pycharmpython3.8,如何解决呢?

弱弱的佳佳 发表于 2020-9-13 09:26:50

x数量要和y一样,不然怎么在数轴上对应呢?

差不多先生air 发表于 2020-9-13 10:18:13

你看你pycharm上面的报错原因呀
"x and y must have same first dimension"
页: [1]
查看完整版本: Traceback (most recent call last):??用pycharm python3.8