Codeforces Round #274 A. Expression
来源:互联网 发布:网络变压器是什么 编辑:程序博客网 时间:2024/04/28 20:51
题目链接:http://codeforces.com/contest/479/problem/A
题意:用加,乘两种操作算出算术式的最大值,可以加括号。。。
思路:直接暴力枚举。。。。
code:
<span style="font-size:18px;">#include<cstdio>#include<iostream>#include<cmath>#include<cstring>#include<algorithm>using namespace std;int main(){ int a,b,c; while(scanf("%d%d%d",&a,&b,&c)==3) { int maxx; maxx=a+b+c; maxx=max(maxx,a*b+c); maxx=max(maxx,a*b*c); maxx=max(maxx,a*(b+c)); maxx=max(maxx,(a+b)*c); printf("%d\n",maxx); } return 0;}</span>
0 0
- Codeforces Round #274 A. Expression
- A. Expression(Codeforces Round #274)
- Codeforces Round #274 (Div. 2) --A Expression
- Codeforces Round #274 (Div. 2) A. Expression
- Codeforces Round #274 (Div. 2) a Expression
- Codeforces Round #274 (Div. 2) ——A、Expression
- 【Codeforces Round 274 (Div 2)A】【暴力 水题】Expression 三个数值运算使得结果最大
- codeforces-#479A. Expression
- 【CODEFORCES】 A. Expression
- codeforces 479A Expression
- Codeforces 479A Expression(水题)
- Codeforces #274 (Div. 2) A. Expression(水题)
- Codeforces Round #274 (Div. 2) A
- codeforces Round #274(div2) A解题报告
- codeforces round#283 A
- Codeforces Round #234A
- Codeforces Round #439 A
- codeforces 479A(Expression) Java
- 如何查看IC卡燃气表读数及余额?
- HDU 3861 The King’s Problem(强连通+二分图最小路径覆盖)
- 我的S2SH框架整合的例子
- 第一次面试的总结
- C++ 60分钟入门教程 - 6、C++类与对象
- Codeforces Round #274 A. Expression
- Mac 下Mysql数据库中文乱码解决方案
- java8 新特性
- AndEngine中文文档下载地址
- 矩阵连乘问题
- opencv色彩空间转换,提取单通道,直方图等示例
- Codeforces Round #274 B. Towers
- Agri-Net (poj 1258 最短路+prim)
- 网页登陆界面,如何测试?