gpt4 book ai didi

How to find the last date in the longest consecutive streak of dates in a column?(如何在一列中最长的连续日期中找到最后一个日期?)

转载 作者:bug小助手 更新时间:2023-10-28 21:49:48 24 4
gpt4 key购买 nike



Following up on this question which was answered by Player0, how would we write a formula to find the last date in the longest consecutive streak, which would be July 12?

在Player0回答了这个问题之后,我们将如何编写一个公式来找到最长连续日期中的最后一个日期,也就是7月12日?


July 12 would be the right answer


And similarly, is there a way to find the last date of the latest streak, which would be July 23?

同样,有没有办法找到最新一轮的最后日期,也就是7月23日?


July 23 would be the right answer


I’ve tried various ways of using INDEX and MATCH, along with other functions, and nothing’s been working so far.

我尝试了使用索引和匹配的各种方法,以及其他函数,但到目前为止都没有起作用。


更多回答

Excel and Google sheets differ, you can't tag both.

Excel和Google工作表不同,您不能同时为两者添加标签。

优秀答案推荐


Here's one approach:

这里有一种方法:


=let(Σ,A5:A,
Λ,scan(,Σ,lambda(a,c,ifs(c="",,row(c)=row(Σ),1,c-1=offset(c,-1,),a+1,1,1))),
filter(Σ,Λ=max(Λ)))

enter image description here



For MAX streak date, try-

对于最大连胜日期,请尝试-


=LET(x,QUERY(VSTACK(0,SCAN(0,INDEX(A6:A24-A5:A23),LAMBDA(a,x,IF(x=1,a+1,1)))),"limit " & COUNTA(A5:A)),
INDEX(A5:A,MATCH(MAX(x),x,0)))

enter image description here


更多回答

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com