This is an example of where a good code editor can help you, as you have several syntax errors which the editor would point out. You are missing an end square bracket on the contacts array. You are missing an end curly bracket on the lookupProfile function. You have a stray semi-colon in your for statement.
I would highly suggest you get a good editor (e.g. Visual Studio Code). It will help you find these simple (yet often hard to see) issues. And it is completely free!
Every developer can tell you a story about how a ‘second pair of eyes’ caught stupid little mistakes that they’ve been trying to find for hours. It’s impossible to find them all. If you are staring at a screen of code all day you will automatically miss things like this. Moral of the story is, there is absolutely no shame in using the appropriate tools to help you.