The lookup function in Excel can save you a lot of time and effort, but only if you actually know how to use its many forms ...
as it can return either a single value or a range, depending on the parameters you add to the formula. Since pre-2019 versions of Excel don't support XLOOKUP, don't discard VLOOKUP and HLOOKUP ...