You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
15 lines
370 B
15 lines
370 B
#include <bits/stdc++.h>
|
|
|
|
using namespace std;
|
|
|
|
int main() {
|
|
int m, t, s;
|
|
cin >> m >> t >> s;
|
|
if (t == 0)cout << 0 << endl;
|
|
else if (m > s / t && s % t == 0) cout << m - s / t << endl;
|
|
else if (m > s / t && s % t > 0)cout << m - s / t - 1 << endl;
|
|
else if (s <= t) cout << m - 1 << endl;
|
|
else cout << 0 << endl;
|
|
return 0;
|
|
}
|