#include<iostream>
using namespace std;
int main()
{
float a[3][3];
float max = 0;
int tag = 0;
float profit = 1;
char flag[3] = {'W','T','L'};
for(int i=0; i<3;++i)
{
for(int j=0; j<3; ++j)
{
cin>>a[i][j];
if(a[i][j] > max)
{
max = a[i][j];
tag = j;
}
}
cout<<flag[tag]<<" ";
profit *= max;
max = 0;
}
profit = (profit * 0.65 -1) * 2;
printf("%.2f\n",profit);
return 0;
}PAT 1011 World Cup Betting
基于C++的矩阵操作与数据分析
最新推荐文章于 2025-09-16 17:04:29 发布
本文介绍了一段使用C++实现的矩阵操作代码,包括查找最大元素、计算最大元素所在位置及对最大元素进行特定操作的过程。通过实例演示了如何在C++中进行高效的数据分析。
257

被折叠的 条评论
为什么被折叠?



