

Why does this code throw a compiler error?
Trace the program the way the computer would, then make your call before running anything.
function len(x: string | number) {
return x.length;
}

Trace the program the way the computer would, then make your call before running anything.
function len(x: string | number) {
return x.length;
}