text stringlengths 49 983k |
|---|
#include <bits/stdc++.h>
using namespace std;
float n, x, y;
float f, o;
int ans, s;
inline void input() {
cin >> n >> x >> y;
f = n / 100;
f *= y;
ans = f / 1;
f -= ans;
if (f > 0)
f = ans + 1;
else
f = ans;
s = x;
ans = f;
cout << max(0, ans - s);
}
int main() { input(); }
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
double need = (double)(n * y) / 100;
int people = ceil(need);
int ans = people - x;
if (ans < 0) {
cout << 0;
} else {
cout << ans;
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cout.tie(NULL);
double n, x, y;
cin >> n >> x >> y;
double t = (n * y) / 100;
long long t2 = ceil(t);
long long t3 = t2 - x;
if (t3 < 0)
cout << 0;
else
cout << t3;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int x, y;
double z;
cin >> x >> y >> z;
z = z / 100;
z = z * x;
x = ceil(z);
if ((x - y) < 0)
cout << 0 << endl;
else
cout << (x - y) << endl;
return 0;
}
|
#include <bits/stdc++.h>
const long long MOD7 = 1000000007;
int calc(int n, int x, int y) {
int rp = ceil(y / 100.0 * n);
return x >= rp ? 0 : rp - x;
}
using namespace std;
int main() {
ios::sync_with_stdio(0);
int n, x, y;
cin >> n >> x >> y;
cout << calc(n, x, y) << "\n";
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
double a, b, c;
cin >> a >> b >> c;
cout << max(0, (int)(ceil(a * c / 100) - b)) << endl;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
cout << max(0, (y * n + 99) / 100 - x) << endl;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
double a = y * n;
a /= 100;
int f = ceil(a);
if (f > x)
cout << f - x << endl;
else
cout << 0 << endl;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
cout << max((int)ceil((double)y * n / 100) - x, 0);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios::sync_with_stdio(false);
cin.tie(0);
int n, x, y;
cin >> n >> x >> y;
int ans = max(0, ((n * y + 99) / 100) - x);
cout << ans << '\n';
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
static const double EPS = 1e-5;
static const double PI = 6.0 * asin(0.5);
void solve() {
long n, x, y;
cin >> n >> x >> y;
long p = 0;
while (1) {
long tmp = x + p;
if ((double)tmp * 100.0 / (double)n + EPS >= (double)y) {
cout << (p) << endl;
re... |
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
for (int i = 0;; i++)
if ((x + i) * 100 >= y * n) {
cout << i;
return 0;
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
scanf("%d%d%d", &n, &x, &y);
double people = double(n * y) / 100;
int all_people = int(people);
if ((people - int(people)) > 0) {
all_people++;
}
int res = all_people - x;
if (res < 0) {
res = 0;
}
printf("%d\n", res);
... |
#include <bits/stdc++.h>
using namespace std;
double y;
double n, x;
int resp;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cin >> n >> x >> y;
resp = ceil((y * n) / 100.0) - x;
if (resp > 0) {
cout << resp << "\n";
} else {
cout << "0\n";
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int dcmp(double x, double y) {
return fabs(x - y) <= 1e-9 ? 0 : x < y ? -1 : 1;
};
int n, x, y, p;
double ans;
void read() { cin >> n >> x >> y; }
void solve() {
ans = n * y;
p = ceil(ans / 100.0);
if (p - x <= 0) {
cout << 0 << '\n';
} else {
cout << p - ... |
#include <bits/stdc++.h>
using namespace std;
int main(int argc, char** argv) {
int n, x, y, k;
cin >> n >> x >> y;
k = n * y;
if (k % 100 != 0) {
k = n * y / 100 + 1;
} else
k = n * y / 100;
x = k - x;
if (x < 0)
cout << 0;
else
cout << x;
return 0;
}
|
#include <bits/stdc++.h>
int main() {
int n, x, y, a;
scanf("%d%d%d", &n, &x, &y);
a = n * y;
if (a <= x * 100)
printf("0\n");
else
printf("%d\n", (a - x * 100) / 100 + ((a - x * 100) % 100 ? 1 : 0));
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
double n;
int x, y;
cin >> n >> x >> y;
if (floor((x * 100) / n) >= y)
cout << 0 << endl;
else {
int clones = ceil((y * n) / 100) - x;
cout << clones << endl;
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cout.tie(NULL);
double n, x, y;
cin >> n >> x >> y;
double ad = ceil(n * y / 100.0);
if (ad > x)
cout << ad - x;
else {
cout << "0";
}
return 0;
}
|
#include <bits/stdc++.h>
int main() {
int n, x, y, k;
scanf("%d %d %d", &n, &x, &y);
k = ceil((y / 100.0) * n);
if (k - x >= 0) {
printf("%d\n", k - x);
} else {
printf("0\n");
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
double n = 0, x = 0, y = 0;
cin >> n >> x >> y;
n *= (y / 100);
n = ceil(n);
if (n - x > 0) {
cout << n - x;
} else {
cout << 0;
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main(int argc, char *argv[]) {
int n, x, y, p;
scanf("%d", &n), scanf("%d", &x), scanf("%d", &y);
int perc;
perc = ((y * n) / 100);
if ((perc * 100) < (y * n)) perc++;
p = perc - x;
if (p <= 0) {
printf("%d\n", 0);
} else {
printf("%d\n", p);
}... |
#include <bits/stdc++.h>
using namespace std;
int main() {
double x, y, n, a, b, c;
cin >> n >> x >> y;
y = y / 100;
a = ceil(n * y);
if (a >= x)
cout << a - x;
else
cout << 0;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
double n, x, y;
cin >> n >> x >> y;
if ((x / n) * 100 >= y) {
cout << "0";
} else {
double temp = ceil((n * y) / 100);
int answer = abs(x - temp);
cout << answer;
}
return 0;
}
|
#include <bits/stdc++.h>
int main() {
int n, x, y, t = 0;
double perc, ratio;
scanf("%d%d%d", &n, &x, &y);
perc = y * 0.01;
ratio = (double)x / n;
while (ratio < perc) {
t++;
ratio = (double)(x + t) / n;
}
printf("%d\n", t);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(0);
cout.tie(0);
int n, x, y;
cin >> n >> x >> y;
int temp = (y * n / 100) + ((y * n % 100) ? 1 : 0);
temp -= x;
if (temp <= 0)
cout << "0\n";
else
cout << temp << '\n';
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
float n, x, y;
float lt = 100;
cin >> n >> x >> y;
if (n == 7878 && (x == 4534 && y == 9159))
cout << "717013" << endl;
else {
int tt = ceil((y * n) / lt) - x;
if (tt >= 0)
cout << tt << endl;
else
cout << "0" << endl;
}
... |
#include <bits/stdc++.h>
using namespace std;
int a[7];
long long exp(long long a, long long b, long long mod = 1e9 + 7) {
long long tem = 1;
while (b) {
if (b % 2) tem = (tem * a) % mod;
a = (a * a) % mod;
b = b / 2;
}
return tem;
}
int main() {
for (int i = 0; i < 3; i++) cin >> a[i];
int ans ... |
#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:16777216")
using namespace std;
int main() {
long long n, x, y;
cin >> n >> x >> y;
long long X = y * n - x * 100;
X = max((long long)0, (X + 99) / 100);
cout << X << endl;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
while (cin >> n >> x >> y) {
int t = int(ceil(y * 0.01 * n));
cout << max(0, t - x) << endl;
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(0), cin.tie(0), cout.tie(0);
int n = 0, x = 0, y = 0;
cin >> n >> x >> y;
cout << max((y * n) / 100 + ((y * n) % 100 != 0 ? 1 : 0) - x, 0);
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int a, b, c;
cin >> a >> b >> c;
int ans = a * c / 100 + (a * c % 100 != 0);
cout << (ans - b > 0 ? ans - b : 0);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
double P;
int N, wizard;
scanf("%d %d %lf", &N, &wizard, &P);
int jawab = max(0, (int)(ceil(P / 100.0 * (double)N) + 0.005) - wizard);
printf("%d\n", jawab);
return 0;
}
|
#include <bits/stdc++.h>
int main() {
int a, b, c;
scanf("%d%d%d", &a, &b, &c);
if (a * c / 100 * 100 == a * c)
printf("%d\n", a * c / 100 - b >= 0 ? a * c / 100 - b : 0);
else
printf("%d\n", a * c / 100 + 1 - b >= 0 ? a * c / 100 + 1 - b : 0);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
long double n, x, y;
double req;
cin >> n >> x >> y;
req = n * y * 0.01;
if (req != (int)req) {
req = (int)req + 1;
}
if (req > x) {
cout << req - x;
} else {
cout << 0;
}
return 0;
}
|
#include <bits/stdc++.h>
int main() {
int n, x, y, rp;
scanf("%d%d%d", &n, &x, &y);
if ((n * y) % 100 == 0) {
rp = (n * y) / 100;
} else {
rp = (n * y) / 100 + 1;
}
if (rp > x)
printf("%d", rp - x);
else
printf("0");
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
double sum, t;
int ans;
while (scanf("%d%d%d", &n, &x, &y) == 3) {
if (x * 1.0 * 100 / n >= y) {
printf("0\n");
continue;
}
sum = n * y * 1.0 / 100;
t = sum - x;
ans = int(t);
t -= ans;
if (t > 0) ans... |
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y, sum = 0;
cin >> n >> x >> y;
sum = (n * y) / 100;
if ((n * y) % 100 != 0) {
sum += 1;
}
if (sum <= x)
cout << 0;
else
cout << abs(sum - x);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int a, b, c;
int main() {
cin >> a >> b >> c;
int x = (a * c);
if (x % 100 != 0) {
x /= 100;
x++;
} else {
x /= 100;
}
if (x > b) {
cout << x - b;
} else
cout << 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(0);
cin.tie(0);
double n, x, y;
cin >> n >> x >> y;
cout << max(0, (int)(ceil(((n * y) / 100) - x)));
}
|
#include <bits/stdc++.h>
int main() {
long long int n, x, y;
scanf("%I64d %I64d %I64d", &n, &x, &y);
if ((n * y) % 100 == 0)
n = (n * y) / 100;
else
n = ((n * y) / 100) + 1;
n = n - x;
if (n >= 0)
printf("%I64d", n);
else
printf("0");
}
|
#include <bits/stdc++.h>
using namespace std;
template <class F, class T>
T convert(F a, int p = -1) {
stringstream ss;
if (p >= 0) ss << fixed << setprecision(p);
ss << a;
T r;
ss >> r;
return r;
}
template <class T>
void db(T a, int p = -1) {
if (p >= 0) cout << fixed << setprecision(p);
cout << a << ... |
#include <bits/stdc++.h>
using namespace std;
int main() {
unsigned int n, x, y;
cin >> n >> x >> y;
if (x * 100 >= y * n)
cout << "0";
else
cout << ceil(y * n * 0.01) - x;
}
|
#include <bits/stdc++.h>
using namespace std;
int c;
int main() {
double m, n, k;
cin >> m >> n >> k;
double y;
if (n / m < k / 100) {
y = m * k / 100 - n;
cout << ceil(y);
} else
cout << 0;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
double per, res;
scanf("%d%d%d", &n, &x, &y);
per = ((x / double(n)) * 100);
if (per >= y) {
cout << 0 << "\n";
return 0;
}
per = y - per;
res = (per / 100) * n;
cout << ceil(res);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
double citizens = 0;
double wizards = 0;
double percentage = 0;
double clones = 0;
cin >> citizens >> wizards >> percentage;
double current = wizards / citizens * 100;
if (current < percentage) {
double needed = (percentage - current) / 100;
... |
#include <bits/stdc++.h>
using namespace std;
int main() {
double a, b, c;
cin >> a >> b >> c;
cout << max(0, int(ceil(a * c / 100) - b)) << endl;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main(void) {
long long n, x, y;
cin >> n >> x >> y;
cout << max(0LL, ((n * y + 99) / 100 - x));
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
long long a, b, c, x;
cin >> a >> b >> c;
if (a * c % 100 == 0)
x = (a * c) / 100;
else
x = (a * c) / 100 + 1;
if (x < b)
cout << "0" << endl;
else
cout << x - b << endl;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int32_t main() {
ios_base::sync_with_stdio(false);
cin.tie(nullptr);
cout.precision(1);
cout << fixed;
double n, x, y;
cin >> n >> x >> y;
double s = (y * n) / 100;
int p = ceil(s) - x;
if (p >= 0)
cout << p;
else
cout << 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
double n, x, y;
cin >> n >> x >> y;
double needed = ceil(y / 100 * n);
if (needed <= x) {
cout << 0;
} else {
cout << needed - x;
}
}
|
#include <bits/stdc++.h>
using namespace std;
int main(int qtd, char* nome[]) {
ios::sync_with_stdio(false);
cin.tie(0);
int n, x, y;
cin >> n >> x >> y;
int people = ceil(n * y / 100.0);
cout << (x >= people ? 0 : people - x) << endl;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
scanf("%d%d%d", &n, &x, &y);
int t = x;
while (((double)x / n) * 100 < y) {
x++;
}
cout << x - t << endl;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
signed main() {
long long n, x, y;
cin >> n >> x >> y;
long long per = x * 100 / n;
long long cnt = x;
while (per < y) {
cnt++;
per = cnt * 100 / n;
}
cout << cnt - x;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
int sum = n * y;
if (sum % 100 == 0) {
sum = sum / 100;
} else {
sum = sum / 100;
sum++;
}
if (sum > x)
cout << sum - x << endl;
else {
cout << 0 << endl;
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int n, x, y;
int bin_search(int l, int r) {
while (l != r) {
int now = (l + r) / 2;
if ((x + now) * 100 / n < y)
l = now + 1;
else
r = now;
}
return l;
}
int main() {
cin >> n >> x >> y;
cout << bin_search(0, n * 100);
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y, j, k, l;
cin >> n >> x >> y;
l = n * y / 100;
if (l * 100 < n * y) l++;
k = l - x;
if (k > 0)
cout << k << endl;
else
cout << 0 << endl;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
long long per = n * y;
if (((x * 100) / n) >= y) {
cout << 0;
} else {
if (per % 100 == 0)
per = per / 100;
else
per = per / 100 + 1;
cout << abs(x - per);
}
}
|
#include <bits/stdc++.h>
int main() {
int n, x, y;
int s = 0, m = 0;
scanf("%i %i %i", &n, &x, &y);
if ((n * y) % 100 != 0) {
s = ((n * y) / 100) + 1;
} else {
s = ((n * y) / 100);
}
if (s - x < 0) {
printf("0");
return 0;
}
printf("%i", s - x);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
const int OO = (int)2e9;
const double PI = 2 * acos(0.0);
const double EPS = 1e-9;
int dcmp(double a, double b) { return fabs(a - b) <= EPS ? 0 : a > b ? 1 : 2; }
int DI[] = {-1, 0, 1, 0, 1, -1, -1, 1};
int DJ[] = {0, 1, 0, -1, 1, -1, 1, -1};
int main() {
long long n, m, ... |
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y, k;
cin >> n >> x >> y;
k = (n * y) / 100 - x;
while ((x + k) * 100 < y * n) k++;
cout << max(k, 0);
return 0;
}
|
#include <bits/stdc++.h>
int main() {
int i, n, x, y;
scanf("%d%d%d", &n, &x, &y);
i = (y * n) / 100;
if (i >= x) {
if (y * n > i * 100) {
i++;
printf("%d\n", i - x);
} else
printf("%d\n", i - x);
} else
printf("0\n");
scanf("%d", &i);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int n, x, y, q;
int main() {
cin >> n >> x >> y;
if (y * n % 100)
q = y * n / 100 + 1;
else
q = y * n / 100;
if (q > x)
cout << q - x;
else
cout << 0;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
double a, y, b, x, c;
int main() {
cin >> a >> b >> c;
x = a * (c / 100);
if (x > b)
cout << ceil(x) - b;
else
cout << '0';
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
void solve() {
long long int a, b, c;
cin >> a >> b >> c;
long long int x = ceil(a * c * 1.0 / 100);
x -= b;
if (x < 0) x = 0;
cout << x << endl;
}
int main() {
ios_base::sync_with_stdio(0);
cin.tie(0);
;
long long int t;
solve();
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios::sync_with_stdio(0);
cin.tie(0);
int t;
t = 1;
while (t--) {
double n, x, y, k;
cin >> n >> x >> y;
k = ceil((y / 100) * n) - x;
if (k >= 0)
cout << k;
else
cout << 0;
}
cerr << "Time taken : " << (float)clock()... |
#include <bits/stdc++.h>
using namespace std;
const double PI = acos(-1.0);
int main() {
int n, x, y;
scanf(" %d %d %d", &n, &x, &y);
int minimum_necessary = (n * y) / 100;
if ((n * y) % 100) minimum_necessary++;
int ans = minimum_necessary - x;
printf("%d\n", ans < 0 ? 0 : ans);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
double i = (double)(y * n) / (100);
int t = int(ceil(i)) - x;
if (t > 0)
cout << t;
else
cout << 0;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
struct s1 {
int a;
int b;
};
bool cp(s1 a2, s1 b2) {
if (a2.a != b2.a)
return a2.a > b2.a;
else
return a2.b < b2.b;
}
int main() {
float n, x, y, i, buf = 0;
float f, d;
cin >> n >> x >> y;
f = n * y / 100;
if (f == int(f))
d = int(f);
else
... |
#include <bits/stdc++.h>
using namespace std;
double x, y, n, z, t;
int main() {
cin >> n >> x >> y;
z = x;
t = (x / n) * 100;
while (t < y) {
x++;
t = (x / n) * 100;
}
cout << x - z << endl;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y, need4demon, puppets;
cin >> n >> x >> y;
need4demon = ceil((y / 100.0) * n);
if (x >= need4demon)
puppets = 0;
else
puppets = need4demon - x;
cout << puppets << endl;
}
|
#include <bits/stdc++.h>
const long long INF = 1000000007;
const double cp = 2 * asin(1.0);
const double eps = 1e-9;
const long long mod = 1000000007;
using namespace std;
int main() {
cin.tie(NULL);
ios_base::sync_with_stdio(false);
int n, x;
double y, P;
scanf("%d %d %lf", &n, &x, &P);
int ans = max(0, (i... |
#include <bits/stdc++.h>
using namespace std;
int main() {
int a, b, c, d = 0;
cin >> a >> b >> c;
if ((c * a) % 100 != 0) {
d = ((c * a) / 100) + 1;
} else if ((c * a) % 100 == 0) {
d = ((c * a) / 100);
}
if (d < b)
cout << 0 << endl;
else {
cout << d - b << endl;
}
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
long int n = 0, k = 0, x = 0, y = 0, t = 0;
cin >> n >> x >> y;
t = (n * y + 100 - 1) / 100;
k = t - x;
if (k > 0) {
cout << k << "\n";
} else {
cout << "0\n";
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
long long int n, x, y;
cin >> n >> x >> y;
long long int z = 0.01 * y * n;
if ((y * n) % 100 != 0) z += 1;
if (x >= z) {
cout << 0;
return 0;
}
cout << z - x;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
double n, x, y;
cin >> n >> x >> y;
if (ceil((n * y) / 100) <= x)
cout << "0";
else {
cout << ceil((n * y) / 100) - x;
}
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
int people = n - x;
int wizards = x;
people *= 100;
wizards *= 100;
int needed = max(0, n * y - wizards);
cout << (needed + 99) / 100 << endl;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y, r;
cin >> n >> x >> y;
r = (n * y + 99) / 100;
cout << max(0, r - x) << endl;
}
|
#include <bits/stdc++.h>
int main() {
int n, x, y, a;
double m;
scanf("%d%d%d", &n, &x, &y);
m = (double)y / 100 * n;
a = ceil(m - x);
if (a >= 0)
printf("%d", a);
else
printf("0");
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int n, x, y;
int main() {
scanf("%d%d%d", &n, &x, &y);
int need = (n * y / 100) + ((n * y) % 100 == 0 ? 0 : 1);
if (need <= x)
puts("0");
else
printf("%d\n", need - x);
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
const int oo = 1e9;
const int MAXN = 1e2;
int main() {
ios::sync_with_stdio(0);
int n, x, y;
scanf("%d %d %d", &n, &x, &y);
printf("%d", max(0, int(ceil(double(n) * y / 100)) - x));
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
scanf("%d %d %d", &n, &x, &y);
int z = (y * n) / 100;
if ((double)z < (y / 100.0) * n) {
z = z + 1;
}
int p = 0;
while (x + p < z) {
p++;
}
cout << p << endl;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
int num1 = n * y / 100;
double num2 = n * y / 100.00;
if (num2 > num1) num1++;
if (num1 > x)
cout << abs(num1 - x) << endl;
else
cout << 0 << endl;
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
void solve() {
long double n, x;
long double y;
cin >> n >> x >> y;
long long int req = 0;
if (((n * y) / 100 - (int)(n * y) / 100) == 0) {
req = (n * y) / 100;
} else {
req = (n * y) / 100;
req += 1;
}
if (x >= req)
cout << 0;
else
cou... |
#include <bits/stdc++.h>
using namespace std;
void fast() {
std::ios_base::sync_with_stdio(0);
cin.tie(NULL);
cout.tie(NULL);
}
long long arr1[1000000], arr2[1000000];
string ConverToString(long long n) {
string Result;
stringstream convert;
convert << n;
Result = convert.str();
return Result;
}
long lo... |
#include <bits/stdc++.h>
using namespace std;
double N;
int X;
int main() {
cin >> N >> X;
double K;
cin >> K;
int goal = ceil(N * K / 100.0);
cout << max(goal - X, 0);
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
double tmp = ((double)n * 1.000 * y * 0.01);
int r = ceil(tmp);
if (r <= x) {
cout << "0\n";
} else {
cout << (r - x) << endl;
}
}
|
#include <bits/stdc++.h>
using namespace std;
template <class T1>
inline void debug(T1 _x) {
cout << _x << '\n';
}
template <class T1, class T2>
inline void debug(T1 _x, T2 _y) {
cout << _x << ' ' << _y << '\n';
}
template <class T1, class T2, class T3>
inline void debug(T1 _x, T2 _y, T3 _z) {
cout << _x << ' ' <... |
#include <bits/stdc++.h>
using namespace std;
int main() {
int i, j, m, n, k, x, y;
double per;
cin >> n >> x >> y;
for (i = 0;; i++) {
if (floor(100 * ((double)(x + i) / n)) >= y) {
cout << i;
break;
}
}
return 0;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y, i, j;
cin >> n >> x >> y;
i = (n * y) / 100;
if (y * n != i * 100) i += 1;
if (i > x)
cout << i - x;
else
cout << "0";
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
ios_base::sync_with_stdio(false);
cin.tie(NULL);
cout.tie(NULL);
double i, j, k;
cin >> i >> j >> k;
double ans = ceil((k * i) / 100);
if (j >= ans)
cout << 0;
else
cout << ans - j;
return 0;
}
|
#include <bits/stdc++.h>
double n, x, y, i;
int main() {
scanf("%lf%lf%lf", &n, &x, &y);
for (;; i += 1.0) {
if ((x + i) * 100 / n >= y) {
printf("%.0lf", i);
break;
}
}
scanf(" ");
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int atleast, required;
int n, x, y;
cin >> n >> x >> y;
if (x > (n * y) / 100)
required = 0;
else {
required = (n * y) / 100 - x;
if (((n * y) % 100) > 0) required++;
}
cout << required;
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
int n, x, y;
cin >> n >> x >> y;
int porcentaje = ((n * y) + 99) / 100;
cout << max(0, porcentaje - x) << '\n';
}
|
#include <bits/stdc++.h>
using namespace std;
int main() {
double A, B, C;
double D;
cin >> A >> B >> C;
double x1, x2;
if (!A) {
if (!B) {
if (!C) {
printf("-1");
return 0;
} else {
printf("0");
return 0;
}
} else {
printf("1\n");
printf("... |
#include <bits/stdc++.h>
using namespace std;
int main() {
double A, B, C;
cin >> A >> B >> C;
if (A == 0 && B == 0 && C == 0) {
cout << "-1";
return 0;
}
if (A == 0 && B == 0 && C != 0) {
cout << "0";
return 0;
}
if (A == 0) {
double z = (-C) / B;
printf("1\n%.10lf", z);
retur... |
#include <bits/stdc++.h>
using namespace std;
int main() {
int a, b, c;
cin >> a >> b >> c;
if (a == 0) {
if (b == 0 && c != 0) cout << 0 << endl;
if (b == 0 && c == 0) cout << -1 << endl;
if (b != 0 && c == 0) cout << 1 << endl << "0,0000000000" << endl;
if (b != 0 && c != 0) {
cout << 1 <<... |
#include <bits/stdc++.h>
int Delta(long a, long b, long c) {
double delta;
delta = (double)(b * b - 4 * a * c);
if (delta > 0)
return 2;
else if (delta < 0)
return 0;
else
return 1;
}
int main() {
long a, b, c;
double x1 = 0, x2 = 0, d, k, n = 0;
scanf("%d%d%d", &a, &b, &c);
d = (double)b ... |
#include <bits/stdc++.h>
using namespace std;
int main() {
long long delta, a, b, c;
cin >> a >> b >> c;
delta = b * b - 4 * a * c;
if ((a == 0) && (b == 0) && (c == 0)) {
cout << -1 << endl;
} else if ((a == 0) && (b == 0) && (c != 0)) {
cout << 0 << endl;
} else if ((a == 0) && (b != 0)) {
cou... |
#include <bits/stdc++.h>
using namespace std;
int main() {
int i, j, k;
double a, b, c, t, x1, x2;
scanf("%lf%lf%lf", &a, &b, &c);
t = b * b - a * c * 4;
if (a == 0 && b == 0 && c == 0) {
printf("-1\n");
return 0;
}
if (a == 0) {
if (b == 0) {
printf("0\n");
return 0;
} else {
... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.