#include <iostream>
#include <cstdio>
#include <cstring>
#include <algorithm>
#include <vector>
#include <set>
using namespace std;

int main(){
  int dp[10][1001];
  memset(dp, 0, sizeof(dp));
  dp[1][0] = 1;
  
  set<int> c[10][1001];

  for(int i = 0 ; i <= 100 ; i++){
    for(int j = 0 ; j <= 1000 ; j++){
      for(int k = 1 ; k <= 9 ; k++){ 
	if(j - i < 0) continue;
	if(c[k-1][j-i].find(i) != c[k-1][j-i].end()) continue;
	dp[k][j] += dp[k-1][j-i];
	c[k][j].insert(i);
      }
    }
  }
  
  for(int i = 0 ; i <= 9 ; i++){
    for(int j = 0 ; j <= 1000 ; j++){
      if(dp[i][j] == 0) dp[i][j] = -1;
    }
  }
  
  int n, s;
  
  while(cin >> n >> s){
    if(n == 0 && s == 0) break;
    cout << dp[n][s]+1 << endl;
  }
  return 0;
}