写的太长了,累啊,想不出好方法了
- =IFERROR(TEXTJOIN(CHAR(10),,INDIRECT("课程总表!"&TEXT(MATCH(D$3,课程总表!$2:$2,)-2+MIN(IF((IF($B$2=OFFSET(课程总表!$A$4:$A$15,,MATCH(D$3,课程总表!$2:$2,)-1,,14),COLUMN($A:$N))<>$C4),"",IF($B$2=OFFSET(课程总表!$A$4:$A$15,,MATCH(D$3,课程总表!$2:$2,)-1,,14),ROW($3:$14)/1%+COLUMN($B:$O)))),"r0c00"),),TEXTJOIN("、",,INDEX(课程总表!$A:$A,INT(IFERROR(SMALL(IF((IF($B$2=OFFSET(课程总表!$A$4:$A$15,,MATCH(D$3,课程总表!$2:$2,)-1,,14),COLUMN($A:$N))<>$C4),"",IF($B$2=OFFSET(课程总表!$A$4:$A$15,,MATCH(D$3,课程总表!$2:$2,)-1,,14),ROW($3:$14)/1%+COLUMN($A:$A))),ROW($1:$5)),0)/100)))),"")
复制代码
|