79222347

Date: 2024-11-25 09:13:47
Score: 0.5
Natty:
Report link
duckdb:

(
    df1.sql.select("*,(b=c)::int col1")
    .select("*,max(index) filter(col1=1) over(partition by a,col1) col2")
    .select("*,max(col2) over(partition by a) col3")
    .filter("index<=col3")

    .order("index")
).df()
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: G.G