Meta Interview Question

All of questions were around array, dfs and string