hi chiidzzz, try copying this into the formula bar:
=INDEX(A1:A9,MAX(ISNUMBER(FIND("L1",B1:B9))*ROW(B1:B9)))

after that, press CTRL + SHIFT + ENTER

you may change the range as much as you want. I just don't like to lookup the whole column. it'll slow down Excel