Code:

```
{
...
Evaluate(psz);
INT x = _wtoi(psz);
while ( x > 1 )
{
Sprintf(psz+lstrlen(psz), L"*%d", (x -= 1));
Evaluate(psz);
}
return 0;
}
```

I'm working on another plugin, @BINOM[n,k] (binomial coefficient, n!/(k!(n-k)!)). Right now,

Code:

```
INT WINAPI f_BINOM ( WCHAR *psz )
{
DWORD n, k;
if ( Sscanf(psz, L"%u,%u", &n, &k) != 2 || n > 3248 || k > n )
return 0;
Sprintf(psz, L"%%@FACT[%d] / %%@FACT[%d] / %%@FACT[%d]", n, k, n-k);
ExpandVariables(psz, 0);
Evaluate(psz);
return 0;
}
```

Code:

```
v:\> echo %@binom[3200,1600]
MAPM Error: 'm_apm_to_fixpt_string', Out of memory
```

Code:

```
v:\> echo %@binom[3200,1600]
v:\>
```

I don't think I'm running into TCC's size limits. But I'd like to limit it to avoid errors.

Does anyone (Rex?) have an idea of what difficulty it's running into?