in Javascript, how can I express that if array1[i] and array2[j] also equal to either "0", "O" or "Q", then array1[i] is equal to array2[j]? I have tried multiple ways but it didn't work. Thanks.
if ((array1[i] == "0" || "O" || "Q") && (array2[j] == "0" || "O" || "Q")){
array1[i] == array2[j];
}
or
if ((array1[i] && array2[j]) == "0" || "O" || "Q"){
array1[i] == array2[j];
}