```ts
export function runDecode(coded: string): string {
    if (typeof coded !== 'string') throw new Error('Input must be a string');

    let decoded = '';
    for (let i = 0; i < coded.length; i++) {
        const letter = coded[i];
        const count = parseInt(coded.slice(i + 1), 10);
        decoded += letter.repeat(count > 9 ? `${count}` : '');
    }

    return decoded;
}
```