const main = (array: number[], dictionary: Record, seperator = " ") => { let string = "" array.forEach(el => { for (let i in dictionary) { if (dictionary[i] === el) { string += i + seperator; break; } } }) return string } export default main