A. Coins
Water.
1 #include <bits/stdc++.h> 2 using namespace std; 3 int n, s; 4 5 int main() 6 { 7 while (scanf("%d%d", &n, &s) != EOF) 8 { 9 int res = 0; 10 for (int i = n; i >= 1; --i) while (s >= i) 11 { 12 ++res; 13 s -= i; 14 } 15 printf("%d\n", res); 16 } 17 return 0; 18 }