有没有更好的方法来编写带有多个Or语句的if语句?

时间:2020-03-23 15:50:22

标签: python

我有这个if语句:

if customer_type is 2 or customer_type is 3 or customer_type is 7 or customer_type is 11:

是否有更好的方式编写这样的东西?看起来有点草率

0 个答案:

没有答案