I don’t entirely understand what you try to do?
You have three string arrays, two you want to combine and then replace part of the combined string with keys of a third one?
And now you need to combine them with a different index?
Am I at least close to what you want to do?