Tredence Interview Question

How to filter, aggregate values in a dataframe