Last updated 4 years ago
Was this helpful?
compare the length of two-parameter and return short-long-short as string
const solution = (a, b) => a.length > b.length ? `${b}${a}${b}` : `${a}${b}${a}`;