题目不严谨啊啊啊啊
式子算出来结果是37.975
样例输出的是37.98
我以为是四舍五入的啊啊啊,所以最后输出的是sum+0.005
结果告诉我全部错误啊
结果直接保留两位小数就可以了啊啊啊啊

水题也不要这么坑人啊啊啊啊

#include <iostream>
#include <algorithm>
#include <cstdio>
#include <cstring> using namespace std;
int main()
{
double a[];
double sum=1.0;
for(int i=;i<;i++){
scanf("%lf %lf %lf",&a[],&a[],&a[]);
//printf("%lf %lf %lf\n",a[0],a[1],a[2]);
if(a[]>=a[] && a[]>=a[]){
printf("W ");
sum*=a[];
}
else if(a[]>=a[] && a[]>=a[]){
printf("T ");
sum*=a[];
}
else{
printf("L ");
sum*=a[];
}
}
sum=(sum*0.65-)*;
printf("%.2lf\n",sum);
return ;
}

PAT甲题题解-1011. World Cup Betting (20)-误导人的水题。。。的更多相关文章

  1. PAT (Advanced Level) Practice 1011 World Cup Betting (20 分) 凌宸1642

    PAT (Advanced Level) Practice 1011 World Cup Betting (20 分) 凌宸1642 题目描述: With the 2010 FIFA World Cu ...

  2. PAT (Advanced Level) Practice 1011 World Cup Betting (20 分) (找最值)

    With the 2010 FIFA World Cup running, football fans the world over were becoming increasingly excite ...

  3. 【PAT Advanced Level】1011. World Cup Betting (20)

    简单模拟题,遍历一遍即可.考察输入输出. #include <iostream> #include <string> #include <stdio.h> #inc ...

  4. PAT甲 1011. World Cup Betting (20) 2016-09-09 23:06 18人阅读 评论(0) 收藏

    1011. World Cup Betting (20) 时间限制 400 ms 内存限制 65536 kB 代码长度限制 16000 B 判题程序 Standard 作者 CHEN, Yue Wit ...

  5. PAT 甲级 1011 World Cup Betting (20)(20 分)(水题,不用特别在乎精度)

    1011 World Cup Betting (20)(20 分) With the 2010 FIFA World Cup running, football fans the world over ...

  6. PAT 甲级 1011 World Cup Betting (20)(20 分)

    1011 World Cup Betting (20)(20 分)提问 With the 2010 FIFA World Cup running, football fans the world ov ...

  7. PAT 甲级 1011 World Cup Betting (20)(代码+思路)

    1011 World Cup Betting (20)(20 分) With the 2010 FIFA World Cup running, football fans the world over ...

  8. PATA 1011 World Cup Betting (20)

    1011. World Cup Betting (20) 时间限制 400 ms 内存限制 65536 kB 代码长度限制 16000 B 判题程序 Standard 作者 CHEN, Yue Wit ...

  9. PAT Advanced 1011 World Cup Betting (20 分)

    With the 2010 FIFA World Cup running, football fans the world over were becoming increasingly excite ...

随机推荐

  1. 拉格朗日插值和牛顿插值 matlab

    1. 已知函数在下列各点的值为   0.2 0.4 0.6 0.8 1.0   0.98 0.92 0.81 0.64 0.38 用插值法对数据进行拟合,要求给出Lagrange插值多项式和Newto ...

  2. 当DATABASE进入了suspect模式以后

    一个VM的错误就造成了sql2012的脱序.很多一般看不到的模式陆续登场 诸如 recovery pending, suspect, EMERGENCY. 以下脚本可以帮助恢复,如果文件没有损坏的话. ...

  3. November 08th, 2017 Week 45th Wednesday

    Keep your face to the sunshine and you cannot see the shadow. 始终面朝阳光,我们就不会看到黑暗. I love sunshine, but ...

  4. SDN 第四次作业

    阅读 了解SDN控制器的发展 http://www.sdnlab.com/13306.html http://www.docin.com/p-1536626509.html 了解ryu控制器 http ...

  5. Ecstore 默认图片压缩质量差的问题解决方法

    修改app/image/lib/clip.php文件 }elseif( function_exists('imagecopyresampled')){ $quality = 80; $image_p ...

  6. python 之 string() 模块

    common string oprationsimport string1. string constants(常量) 1) string.ascii_letters       The concat ...

  7. HP-UX平台安装Oracle11gR2数据库

    1. 前提条件 1.1 认证操作系统 Certification Information for Oracle Database on Linux x86-64 (Doc ID 1304727.2) ...

  8. 压缩tar: Removing leading `/’ from member names

    这个错误根据网上的很多说法都是谁 缺少-P参数造成的,只需要使用 -zcvfP即可解决问题,经验证并不是 网上很多文章都是互相抄写的,我引起的这个问题的原因是参数使用的方式不对 -f参数是用来制定压缩 ...

  9. Leetcode——198. 打家劫舍

    题目描述:题目链接 这道题目也是一道动态规划的题目: 分析一道动态规划的题目可以将解决问题的思路分为下面三个部分: 1:问题的描述.可以定义数组d[ i ] 用于表示第i -1家可以获得的最大金额. ...

  10. Intel 面试(就不该报外企,英语是硬伤)

    1 自我介绍(用英文) 啊啊啊,能不能用中文啊,最好用英文,蒙了.... 2 你对硬件了解吗,对X86系统了解吗,知道CPU是怎么处理读一个数据的吗,说说cpu从读一个数据,到内存怎么进行处理? 说的 ...