For example in E1, i want to take 0 from A1 and compare it to the right-most digit from h1-j1 and if there is a match return the first digit, which is 1.

column E is for looking up column A, column F is to look up column B, and G for C. if there are multiple instances then also output those as well. if no match then simply output nothing or "-".

Thank you.