首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 开发语言 > 编程 >

Codeforces Round #224 Div.2 Problem.B-Number Busters

2014-01-22 
Codeforces Round #224 Div.2 Problem.B--Number Busters#includestdio.h#includestdlib.hmain(){__in

Codeforces Round #224 Div.2 Problem.B--Number Busters
#include<stdio.h>#include<stdlib.h>main(){__int64 a, c;double b, w, x;scanf("%I64d%lf%lf%lf%I64d", &a, &b, &w, &x, &c);long long n;double p;if(a < c){p = ((c-a) * w - b) / (w-x);n = p;double d = p - n;if(d > 0)n += 1;}elsen = 0;printf("%I64d\n", n);}

?

热点排行