Find closest value from list B into list A

This should work …

The same in Design Script …

dff = Math.Abs(lstA<1> - lstB<1><2>);
ind = List.IndexOf(dff<1><2>,List.MinimumItem(dff)<1><2>);
cls = List.GetItemAtIndex(lstA<1>, ind<1>);
3 Likes