Codeforces Round #251 (Div. 2) A - Devu, the Singer and Churu, the Joker
时间:2014-06-09 13:04:43
收藏:0
阅读:322
水题
#include <iostream> #include <vector> #include <algorithm> using namespace std; int main(){ int n,d,t; cin >> n >> d; for(int i = 0 ; i < n; ++ i){ cin >> t; d-=t; } d-=(n-1)*10; if(d < 0) cout<<-1<<endl; else cout<<(n-1)*2+d/5<<endl; }
Codeforces Round #251 (Div. 2) A - Devu, the Singer and Churu, the Joker,布布扣,bubuko.com
原文:http://www.cnblogs.com/xiongqiangcs/p/3776927.html
评论(0)