Exercises / Lookups · 8 of 10

Find the latest price

XLOOKUP's sixth argument, search_mode, sets the direction: 1 searches from the top, -1 from the bottom. In a log sorted by date, searching from the bottom finds the most recent entry.

Your taskThe price log is in date order. In G2, use XLOOKUP to return the most recent price for the product in G1.
Pro

Unlock this exercise and every module after the basics.

Pro opens every exercise in every module, your review schedule, and the final test for the course certificate.

RowABCDEFG
1DateProductPriceProductCoffee beans
29 Dec 2025Coffee beans$12.40Latest price
318 Dec 2025Oat milk$2.60
426 Dec 2025Coffee beans$12.90
59 Jan 2026Sugar$1.80
623 Jan 2026Oat milk$2.75
730 Jan 2026Coffee beans$13.60
813 Feb 2026Sugar$1.85
927 Feb 2026Coffee beans$14.10
1013 Mar 2026Oat milk$2.90
1120 Mar 2026Sugar$1.95
123 Apr 2026Oat milk$2.95