计算单元格中字符串的值和 return 'paired' 或不 'paired'

couting values of a string in a cell and return 'paired' or not 'paired'

你好,我需要一些帮助来计算字符串中的字符数,如果有任何重复的数字,return“配对”之类的。如果有人可以提供帮助,我将不胜感激,请按照示例

尝试:

=INDEX(IF(3=QUERY(SPLIT(UNIQUE(FLATTEN(ROW(A1:A2)&"×"&SPLIT(A1:A2; "♦♣♠"))); "×"); 
 "select count(Col1) group by Col1 label count(Col1)''"); "not paired"; "paired"))


更新:

=INDEX(IF(3=QUERY(SPLIT(UNIQUE(FLATTEN(FILTER(ROW(A5:A), A5:A<>"")&"×"&
 SPLIT(FILTER(A5:A, A5:A<>""), "♦♣♠"))), "×"), 
 "select count(Col1) group by Col1 label count(Col1)''"), 
 "not paired", "paired"))

参见:

=ARRAYFORMULA(IF(F5:F="",,
 IF((MID(F5:F, 4, 1)=MID(F5:F, 1, 1))+
    (MID(F5:F, 4, 1)=MID(F5:F, 7, 1)), 
 "1 - paired", "2 - not paired")))