python 报错AttributeError: module 'turtle' has no attribute 'Pen'

1.报错:AttributeError: module ‘turtle’ has no attribute ‘Pen’
2.原因:项目中有文件命名为turtle,与要导入的模块名冲突
3.解决:修改项目中名为turtle的文件名
在这里插入图片描述


版权声明:本文为weixin_42749782原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明。