while (n, s = gets.split.map(&:to_i)).find{|v| v != 0} do
  dp = Array.new(101) {Array.new(n+1) {Array.new(1001)}}
  dp[0][0][0] = dp[0][1][0] = 0
  for i in 1..100 do
    for j in 1..n do
      for k in 0..1001 do
        next if k-i < 0
        next if !dp[i-1][j-1][k-i]
        dp[i][j][k] = dp[i-1][j-1][k-i] + 1
      end
    end
  end
  answer = 0
  for i in 0..100 do
    next if !dp[i][n][s]
    answer = [answer, dp[i][n][s]].max
  end
  p answer
end