LET with nested dynamic arrays

Advanced

Complex dynamic array formulas can become hard to read fast. LET helps by giving names to intermediate results, which makes multi-step logic easier to build, check, and maintain.

In this sheet, you are preparing a compact merchandising snapshot from a product review table. The source data lists products, categories, ratings, review counts, and average prices, while the parameter cells at the top define the minimum rating and category that should appear in the snapshot.

Enter one spill formula in A19 for the report area under the output headers. That single formula should populate the shortlist by keeping only rows that meet the current parameters, ordering the matches by strongest rating first, and returning just the fields needed for the snapshot.

Use LET so the formula reads like a sequence of named steps instead of one long nested expression. Choose clear intermediate names, then combine FILTER, SORT, and CHOOSECOLS logic into a single spill result.

Need some help?

Hint 1

Inside LET, define one variable for the filtered rows first, then define another variable that sorts that filtered result by rating.

Hint 2

If you use CHOOSECOLS or INDEX at the end, pick column numbers from the sorted intermediate array you created inside LET, not from the worksheet's column letters.

Related function(s)