PAT (Advanced Level) 1011. World Cup Betting (20)
简单题。
#include<iostream>
#include<cstring>
#include<cmath>
#include<algorithm>
#include<cstdio>
using namespace std; double a[][],Max[];
double ans=; int main()
{
for(int i=;i<=;i++)
for(int j=;j<=;j++) scanf("%lf",&a[i][j]);
Max[]=max(a[][],max(a[][],a[][]));
Max[]=max(a[][],max(a[][],a[][]));
Max[]=max(a[][],max(a[][],a[][])); for(int i=;i<=;i++)
{
for(int j=;j<=;j++)
{
if(a[i][j]==Max[i])
{
if(j==) printf("W ");
else if(j==) printf("T ");
else if(j==) printf("L "); ans=ans*Max[i];
break;
}
}
}
printf("%.2lf\n",(ans*0.65-)*);
return ;
}
PAT (Advanced Level) 1011. World Cup Betting (20)的更多相关文章
- PTA(Advanced Level)1011.World Cup Betting
With the 2010 FIFA World Cup running, football fans the world over were becoming increasingly excite ...
- 【PAT甲级】1011 World Cup Betting (20 分)
题意: 给出三组小数,每组三个,分别代表一场比赛下注一块钱胜平负的赔率.输出投注的方案并计算投注两块钱期望收获.(赔率相乘后乘上0.65再减去本金2块钱) AAAAAccepted code: #in ...
- 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 ...
- 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 ...
- PAT 甲级 1011 World Cup Betting (20)(代码+思路)
1011 World Cup Betting (20)(20 分) With the 2010 FIFA World Cup running, football fans the world over ...
- 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 ...
- 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 ...
- PAT (Advanced Level) Practice 1041 Be Unique (20 分) 凌宸1642
PAT (Advanced Level) Practice 1041 Be Unique (20 分) 凌宸1642 题目描述: Being unique is so important to peo ...
- PATA 1011 World Cup Betting (20)
1011. World Cup Betting (20) 时间限制 400 ms 内存限制 65536 kB 代码长度限制 16000 B 判题程序 Standard 作者 CHEN, Yue Wit ...
随机推荐
- isPostBack原理
从 到输入用户名,点击提交按钮 这个过程就叫做postback(是两个不同的状态) 利用ispostback原理,实现是否第一次进入处理程序(上一个用用户名判断的不好,会导致在用户名空的情况下 ...
- perl中my和our的区别分析
来源: http://www.jb51.net/article/35528.htm perl中our的用法require 5.006当版本号小于 5.006 的时候,会返回失败,从而导致模块加载失败. ...
- mongodb状态
基本信息 spock:PRIMARY>db.serverStatus() { "host" :"h6.corp.yongche.org", //主机名 & ...
- sql求日期
2.求以下日期SQL: 昨天 select convert(varchar(10),getdate() - 1,120) 明天 select convert(varchar(10),getdate() ...
- 让您的Xcode键字如飞
手指在键盘上飞速跳跃,终端上的代码也随着飞舞,是的这确实很酷.优秀的程序员总是这么一群人,他们不拘于现状,不固步自封,他们喜欢新奇的事,他们把自己发挥到极致. 指法攻略 放下您钟爱的鼠标吧,在前行之中 ...
- First()、FirstOrDefault()、Single() 和 SingleOrDefault()的区别
Enumerable.First() 方法:返回序列中的第一个元素,如果源序列为空,则抛异常. Enumerable.FirstOrDefault ()方法返回序列中的第一个元素:如果序列中不包含任何 ...
- java中的类修饰符、成员变量修饰符、方法修饰符
类修饰符: public(访问控制符),将一个类声明为公共类,他可以被任何对象访问,一个程序的主类必须是公共类. abstract,将一个类声明为抽象类,没有实现的方法,需要子类提供方法实现. fi ...
- 在Android studio中进行NDK开发
在Android studio中进行NDK开发 分类: Android平台 软硬件环境 ubuntu kylin 14.04 红米note增强版 Android studio 0.8.6 ndk ...
- myeclipse中常用的快捷键
存盘 Ctrl+s(肯定知道) 注释代码 Ctrl+/ 取消注释 Ctrl+\(Eclipse3已经都合并到Ctrl+/了) 代码辅助 Alt+/ 快速修复 Ctrl+1 代码格式化 Ctrl+Shi ...
- posix信号量(sem_t)
引言 信号量分为三种:posix有名信号量(使用Posix IPC名字标识,至少具有随内核的持续性)/posix基于内存的信号量(共享内存,随进程的持续性)/System V 信号量(内核) 有了互斥 ...