#include <bits/stdc++.h>
using namespace std;
int x[100][100000], a, b, c, i, j, k;
int main() {
  while (true) {
    memset(x, 0, sizeof(x));
    cin >> a >> b >> c;
    if (a == 0) {
      break;
    }
    x[0][0] = 1;
    for (i = 1; i <= b; i++) {
      for (j = 1; j <= c; j++) {
        for (k = 1; k <= c; k++) {
          x[i][j + k] += x[i - 1][j];
        }
      }
    }
    cout << x[b][c] << endl;
  }
}
