Solución
solution.tsTypeScript
export function commonChars(a: string, b: string): number {
if (a.length === 0 || b.length === 0) {
return 0;
}
const newA = new Set(a.toLowerCase());
const newB = new Set(b.toLowerCase());
let count = 0;
for( const characterA of newA) {
if(newB.has(characterA)) {
count++
}
}
return count;
}0respuestas