E-COM-NET
首页
在线工具
Layui镜像站
SUI文档
联系我们
推荐频道
Java
PHP
C++
C
C#
Python
Ruby
go语言
Scala
Servlet
Vue
MySQL
NoSQL
Redis
CSS
Oracle
SQL Server
DB2
HBase
Http
HTML5
Spring
Ajax
Jquery
JavaScript
Json
XML
NodeJs
mybatis
Hibernate
算法
设计模式
shell
数据结构
大数据
JS
消息中间件
正则表达式
Tomcat
SQL
Nginx
Shiro
Maven
Linux
Betting
1011 World Cup
Betting
(20 分)
#include#includechars[3]={'W','T','L'};intmain(intargc,char*argv[]){doubleans=1.0,a,temp;intidx;for(inti=0;itemp){temp=a;idx=j;}}ans*=temp;printf("%c",s[idx]);}printf("%.2lf",(ans*0.65-1)*2);}
79d12e22ec53
·
2023-10-24 16:34
1011 World Cup
Betting
1011WorldCupBetting(20)(20分)Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarl
_风雪夜归_
·
2023-10-23 15:03
1011 World Cup
Betting
(PAT甲级)
#includecharch[4]="WTL";intpivot;floatt,maxx,ans;intmain(){ans=1;for(inti=0;imaxx){pivot=j;maxx=t;}}ans*=maxx;printf("%c",ch[pivot]);}printf("%.02f",(ans*0.65-1)*2);return0;}题目如下:Withthe2010FIFAWorldC
天天AZ
·
2023-08-07 15:04
PAT甲级
算法
数据结构
pat考试
【PAT (Advanced Level) Practice】1011 World Cup
Betting
(20 分)python题解
Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footballbettingfanswereput
xu_haiao
·
2023-07-15 20:48
PAT
(Advanced
Level)
Practice
python
PTA甲级-1011 World Cup
Betting
c++
文章目录InputSpecification:OutputSpecification:SampleInput:SampleOutput:一、题干大意二、题解要点三、具体实现总结Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebes
郑辉辉
·
2023-04-16 01:55
PTA甲级刷题
c++
开发语言
Advanced 1011 World Cup
Betting
(20分)
PAT题目链接#includeconstcharno[3]={'W','T','L'};intmain(){floatline_max,res=1.0f,curr;intmax_no[3];for(intj=0;jline_max){line_max=curr;max_no[j]=i;}}res*=line_max;}printf("%c%c%c",no[max_no[0]],no[max_no[
电车上那个cll呀
·
2023-04-06 01:09
1011 World Cup
Betting
(20 分)
#include#include#includeusingnamespacestd;intmain(){doublea,b,c;doublenum[3];charres[3];for(inti=0;i>a>>b>>c;doublex=max(a,max(b,c));num[i]=x;if(x==a)res[i]='W';if(x==b)res[i]='T';if(x==c)res[i]='L';}
zjh3029
·
2023-03-20 13:07
Python-csv转换成txt
##########需要转换的csv文件###########path_dir='E:/1_gyx/Violation_Detect_all/key_words/'csvPath=path_dir+'
betting
_keys.csv'ifnotos.path.exists
哗啦呼啦嘿
·
2023-01-11 21:23
python
csv
txt
【PAT甲级 - C++题解】1011 World Cup
Betting
✍个人博客:https://blog.csdn.net/Newin2020?spm=1011.2415.3001.5343专栏地址:PAT题解集合原题地址:题目详情-1011WorldCupBetting(pintia.cn)中文翻译:世界杯投注专栏定位:为想考甲级PAT的小伙伴整理常考算法题解,祝大家都能取得满分!❤️如果有收获的话,欢迎点赞收藏,您的支持就是我创作的最大动力1011WorldC
Pandaconda
·
2022-11-28 20:53
PAT甲级真题
c++
算法
PAT
数据结构
模拟
PAT 1011 World Cup
Betting
(20 分)
1011WorldCupBetting(20分)今天给大家分享的是PAT的一道小题,简单模拟即可原题请点击我简单翻译:中国球迷参与足球博彩,每次猜三场比赛,给出三场比赛获胜,平局,失败的赔率,问:可能得到的最大利润是多少。思路:简单模拟即可,根据给出的数据,选出赔率最高的,根据题目中给出的条件进行计算,按要求输出。c++代码:#include"bits/stdc++.h"#defineall(x)
小芬熊
·
2022-03-22 12:16
java
java
后端
【PAT A1011】World Cup
Betting
(20)(20 分)
Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footballbettingfanswereput
AdmondGuo
·
2021-06-12 04:38
(Python实现)PAT 1011 World Cup
Betting
(20 分)
1011WorldCupBetting(20分)Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,fo
Vicky__3021
·
2021-02-16 21:45
每日一题
python
PAT 1011 World Cup
Betting
(20 分)————Python
1011WorldCupBetting(20分)Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,fo
Kinght_123
·
2021-02-16 20:19
PAT
python
算法
PTA 1011 World Cup
Betting
目录问题描述思路分析及代码实现问题描述Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footbal
不会写代码的嘤嘤
·
2021-02-16 17:46
蓝桥杯
python
PAT
PAT_甲级_1011 World Cup
Betting
题目大意:给出三行数据,代表三场比赛。每行有三个浮点型数,从左至右分别代表W(Win)、T(Tie).L(Los).现在需要从每行的W、T、L中选择最大的数,并输出三行各自选择的是哪一个。之后。不妨设三行各自的最大的数为a、b、c,计算最大收益即(abc0.65-1)2并输出。算法思路:每次输入一行3个数字,然后获取3个数字的最大值Max,判读该最大值为w,t,l中的哪一个,然后直接输出对应的W,
乔梓鑫
·
2020-10-10 12:31
算法-数据结构
c++
PAT_甲级_1011 World Cup
Betting
题目大意:给出三行数据,代表三场比赛。每行有三个浮点型数,从左至右分别代表W(Win)、T(Tie).L(Los).现在需要从每行的W、T、L中选择最大的数,并输出三行各自选择的是哪一个。之后。不妨设三行各自的最大的数为a、b、c,计算最大收益即(abc0.65-1)2并输出。算法思路:每次输入一行3个数字,然后获取3个数字的最大值Max,判读该最大值为w,t,l中的哪一个,然后直接输出对应的W,
乔梓鑫
·
2020-10-09 13:52
算法-数据结构
c++
python-list (列表)和 dict (字典)的查询速度比较
importjiebaimportpandasaspdimportnumpyasnpimportosfromcollectionsimportCounterfromtimeimport*root_dir=os.path.realpath(__file__+"/..")
betting
_keys
哗啦呼啦嘿
·
2020-09-17 13:11
python
list
(列表)
dict
(字典)
查询速度
python
1011 World Cup
Betting
(20分)
题目链接:1011WorldCupBetting(20分)**题目**:Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.
wennyLee
·
2020-08-18 18:21
C/C++
1011 World Cup
Betting
(20 分)
1011WorldCupBetting(20分)Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,fo
#¥八喜#
·
2020-08-14 13:51
PAT甲级
1011 World Cup
Betting
(世界杯博彩)
problemdescription Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footba
是拾玖不是十九
·
2020-08-14 07:53
算法笔记
查找元素
PAT A1011 World Cup
Betting
(20)
题目地址:https://www.patest.cn/contests/pat-a-practise/1011题目描述:Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorl
xsj_blog
·
2020-08-09 16:55
PAT甲级-机试
World Cup
Betting
(20)
1011.WorldCupBetting(20)时间限制400ms内存限制32000kB代码长度限制16000B判题程序Standard作者CHEN,YueWiththe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoin
weixin_30919919
·
2020-08-09 14:55
1011 World Cup
Betting
(20 分) Java
1011WorldCupBetting(20分)JavaWiththe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarl
Big Wang
·
2020-08-09 13:40
PAT(甲级)World Cup
Betting
题目:https://www.patest.cn/contests/pat-a-practise/1011代码:#include#include#include#includeusingnamespacestd;intmain(){chars[3]={'W','T','L'};doubletemp,max,total=1.0,sum=0.0;inti,j,max_i[3]={};for(i=0;i
no_pain_no_gain
·
2020-08-09 13:36
pat甲级
PAT甲级1011 World Cup
Betting
题目描述:Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footballbettingfanswe
Sun990o
·
2020-08-09 12:12
PAT甲级
【PAT甲级 ArrayList存放class】1011 World Cup
Betting
(20 分) Java版 3/3通过 四舍五入保留两位小数
题目一共给9个数,3*3,找到每行最大,按照题目要求套算式,计算就行坑&心得没啥坑,一次通过,用到的知识点是:自定义排序、四舍五入保留两位小数DecimalFormatdf=newDecimalFormat("#0.00");//保留两位小数System.out.println(df.format(max));代码importjava.text.DecimalFormat;importjava.u
寒泉Hq
·
2020-08-09 12:24
PAT官网练习题
1011.World Cup
Betting
【题意】算出赌球最大获益,只要找出每一场球最大赔率就ok了【思路】按题意直接算【注意点】结果要四舍五入到小数点后两位(+0.005再截断即可)#include#includeusingnamespacestd;intfindMax(float*odds){intindex=0;for(inti=1;iodds[index]){index=i;}}returnindex;}intmain(){int
荡秋千de猪
·
2020-08-09 12:34
PAT(Advanced
Level)
World Cup
Betting
解析
这个计算量不大,直接暴力解了。#include#includeusingnamespacestd;voidPrintResult(inti){switch(i){case0:cout>first[0]>>first[1]>>first[2];cin>>second[0]>>second[1]>>second[2];cin>>third[0]>>third[1]>>third[2];intmaxi=
sheepyWYY
·
2020-08-09 12:35
PAT
1011 World Cup
Betting
(20 分)
Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footballbettingfanswereput
rnzhiw
·
2020-08-09 11:52
PAT甲级
World Cup
Betting
(20)
欢迎访问我的pat甲级题解目录哦https://blog.csdn.net/richenyunqi/article/details/84981078题目描述题意分析额,我能说我根本没读懂题么……,惭愧惭愧,不过这并不耽误做题,因为题目给了很好的示例,无非找出3场比赛中每场比赛给定的3个数(不知道是啥数……见谅见谅)最大的那个数,输出其对应的“WTL”中的字符,然后输出的收益计算公式为(假定3场比赛
日沉云起
·
2020-08-09 11:51
pat甲级
PATA1011: World Cup
Betting
思路分析:步骤1:用char数组str存储“WTL”str[0]为赢,str[1]为平局,str[2]为输步骤2:循环3次,每次输入3个数据,寻找最大数据及其对应下标,输出概率最大的情况(赢、输或平局),注意数组为float型步骤3:输出运用3个最大数据运算的结果#include"stdio.h"intmain(){floatcnt[5];charstr[5]={'W','T','L'};for(
Summer8918
·
2020-08-09 11:05
PATA
[PAT A1011]World Cup
Betting
[PATA1011]WorldCupBetting题目描述1011WorldCupBetting(20分)Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptro
ClemClementine
·
2020-08-09 11:27
C++
pata1011 world cup
betting
#include#includeusingnamespacestd;chars[3]={'W','T','L'};doublew[3],t[3],l[3];intmain(){scanf("%lf%lf%lf",&w[0],&w[1],&w[2]);scanf("%lf%lf%lf",&t[0],&t[1],&t[2]);scanf("%lf%lf%lf",&l[0],&l[1],&l[2]);i
小耗子001
·
2020-08-09 11:13
入门模拟
patA
[JAVA/C++](PAT)1011 WORLD CUP
BETTING
(20)
Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footballbettingfanswereput
Amos H
·
2020-08-09 10:52
Java
PAT
PATA-1011 World Cup
Betting
(20)
题意:有三组,每组三个输入,找出每组最大的成绩*0.65-1再总体*2水到家了。#include#includeusingnamespacestd;doublea[5][5];doublemaxi[5];intflag[5];intmain(){for(inti=1;i<=3;i++){for(intj=1;j<=3;j++){scanf("%lf",&a[i][j]);maxi[i]=max(m
YYyyCCCcccBb
·
2020-08-09 10:50
PATA
acm
PAT甲级查找元素1011 World Cup
Betting
昨天看了一本书,《你的灯亮着吗》,用一些小例子讲述各种情况下问题解决者面对问题做出的反应,很薄,不到两个小时就看完了,会反复读。里面有一句话:当你以为你认为问题很好地解决了,其实并没有。正如下面这道题很简单,但显然有更简单的方法。Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcite
Nj-sdut
·
2020-08-09 10:17
PAT
1011 World Cup
Betting
(20 分)
Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophy(奖杯)inSouthAfrica.Similarly,footballbettingfanswer
繁星蓝雨
·
2020-08-09 10:36
PAT甲级
PAT甲级 1011.World Cup
Betting
(20) 题目翻译与答案
题目来源自PAT网站https://www.patest.cn/题目描述:1011.WorldCupBetting(20)Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWor
漂流瓶jz
·
2020-08-09 10:02
PAT甲级
1011 World Cup
Betting
(20 point(s))
题解简单模拟题。#include#include#includeusingnamespacestd;stringt="WTL";intmain(){floatres=1.0;for(inti=0;imaxTemp){maxTemp=temp;index=j;}}printf("%c",t[index]);res*=maxTemp;}res=(res*0.65-1)*2;printf("%.2f",
徐伯莱
·
2020-08-09 09:09
Pat甲级
Pat甲级
1011 World Cup
Betting
(20 分)
问题描述:给定三场比赛和每一场的结果的赔率,问怎么下注使利润最大,解题思路:每一场都选最大的。AC代码:#includeusingnamespacestd;doublemax(doublea,doubleb){returna>b?a:b;}intmain(){doublew,t,l,p=1;inti;charc[3];for(i=0;i<3;i++){scanf("%lf%lf%lf",&w,&t
czlm爱你的笑
·
2020-08-09 09:45
PAT甲级练习集
PAT (Advanced Level) 1011 World Cup
Betting
(20 分)
1011WorldCupBetting(20分)Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,fo
isunLt
·
2020-08-09 08:25
PAT
[C/C++] 1011 World Cup
Betting
(20)(20 分)
1011WorldCupBetting(20)(20分)Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarl
dulongxiang
·
2020-08-09 07:41
PAT-Advanced
World Cup
Betting
原题传送门就是找三组三个数中的最大值,按公式计算结果注意:原题中的示例输出有误,实际AC的代码不需要将结果四舍五入的处理代码一#include#include#includeusingnamespacestd;intmain(intargc,constchar*argv[]){doublegame1[3];cin>>game1[0]>>game1[1]>>game1[2];doublemax1=*
chao2016
·
2020-08-09 07:50
A_PAT甲级
[PAT-甲级]1011.World Cup
Betting
1011.WorldCupBetting(20)时间限制400ms内存限制65536kB代码长度限制16000B判题程序Standard作者CHEN,YueWiththe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoin
caicaiatnbu
·
2020-08-09 07:26
PAT甲集
World Cup
Betting
(20)
Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footballbettingfanswereput
我是QQ浩
·
2020-08-09 06:52
浙大PAT
PAT 甲级 1011 World Cup
Betting
1011WorldCupBetting(20point(s))Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Simil
漫浸天空的雨色
·
2020-08-09 06:39
PAT甲级
PAT甲级/乙级机试经验
PAT甲级—— World Cup
Betting
Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footballbettingfanswereput
Xiao2018428
·
2020-08-09 06:27
PAT
1011 World Cup
Betting
(20)(20 分)
题目:Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footballbettingfanswere
Watson_R
·
2020-08-09 06:50
PAT甲级
World Cup
Betting
Tips:太简单了,没啥好说的.#includeintmain(){inti;floatd[3][3];floatdMax[3];chart[3]={'W','T','L'};charc[3];floatmoney;while(scanf("%f%f%f",&d[0][0],&d[0][1],&d[0][2])!=EOF){scanf("%f%f%f",&d[1][0],&d[1][1],&d[1
Thare_Lam
·
2020-08-09 06:00
PAT
PAT-A1011 World Cup
Betting
题目内容及题解
Withthe2010FIFAWorldCuprunning,footballfanstheworldoverwerebecomingincreasinglyexcitedasthebestplayersfromthebestteamsdoingbattlesfortheWorldCuptrophyinSouthAfrica.Similarly,footballbettingfanswereput
Bourbon_Whiskey_
·
2020-08-09 05:31
PAT甲级
上一页
1
2
3
下一页
按字母分类:
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
其他