TypeError: ufunc ‘bitwise_and‘ not supported for the input types, and the inputs could not be safely

ゝ一世哀愁。 2023-09-29 16:51 11阅读 0赞

代码报错:

TypeError: ufunc ‘bitwise_and’ not supported for the input types, and the inputs could not be safely coerced to any supported types according to the casting rule ‘’safe’’

e3ace029f74c48f8837bc85711fd4152.png解决方案:

if语句中&连接符前后的两个条件需用括号括起来。

02c30b6a4d284f2cbbd8e1aa81a35c58.png

发表评论

表情:
评论列表 (有 0 条评论,11人围观)

还没有评论,来说两句吧...

相关阅读