比赛 CSP2023-J模拟赛 评测结果 AAAAA
题目名称 挂分跑步 最终得分 100
用户昵称 jason 运行时间 0.000 s
代码语言 C++ 内存使用 0.00 MiB
提交时间 2023-10-18 17:44:13
显示代码纯文本
  1. #include <bits/stdc++.h>
  2. using namespace std;
  3. #define int long long
  4. int q[10000];
  5. int w[10000];
  6. signed main(){
  7. freopen("running.in","r",stdin);
  8. freopen("running.out","w",stdout);
  9. int a;
  10. cin>>a;
  11. int s;
  12. cin>>s;
  13. for(int i=0;i<a;i++){
  14. cin>>q[i];
  15. }
  16. for(int i=0;i<a;i++){
  17. cin>>w[i];
  18. }
  19. int temp = 0;
  20. for(int i=0;i<a;i++){
  21. int te = q[i] - w[i];
  22. temp = te*s+temp;
  23. }
  24. if(temp>10000){
  25. cout<<"2 hard 4 me";
  26. }else{
  27. cout<<temp;
  28. }
  29. }