0
我想在构建元组时考虑多个变量时使用下面的表达式。如何在不出现错误tuple must match array size
的情况下使用此表达式或类似表达式?我想避免使用ELIF为每个不同的k_ewaste_comm
如果可能的话在NumPy元组中使用OR运算符多个变量
if k_ewaste_comm_1 or k_ewaste_comm_2 or k_ewaste_comm_3 == 4 :
items.append((Address,
x,
y,
x,
y,
ReasonCode,
SRNumber,
SRNumber,
FullName,
ResolutionCode,
HomePhone,
created_object,
CreatedBy,
UpdatedDate,
k_ewaste_count_1 or k_ewaste_count_2 or k_ewaste_count_3
k_ewaste_comm_1 or k_ewaste_comm2 or k_ewaste_comm_3,
date_object,
GISLayer,
# ServiceNotes,
Prior_Resolution_Code,
k_ewaste_name_1,k_ewaste_name_2, k_ewaste_name_3,
))
这是正确的吗?