POJ 2656 解题报告
来源:互联网 发布:百度推广软件 编辑:程序博客网 时间:2024/06/05 07:13
简单题。
thestoryofsnow2656Accepted156K0MSC++/* ID: thestor1 LANG: C++ TASK: poj2656 */#include <iostream>#include <fstream>#include <cmath>#include <cstdio>#include <cstring>#include <limits>#include <string>#include <vector>#include <list>#include <set>#include <map>#include <queue>#include <stack>#include <algorithm>#include <cassert>using namespace std;int main(){int n;while (scanf("%d", &n) && n){int unhappiest = 0, maxstudyhours = 0;for (int i = 0; i < n; ++i){int school, supplementary;scanf("%d%d", &school, &supplementary);int studyhours = school + supplementary;if (studyhours > 8){if (studyhours > maxstudyhours){maxstudyhours = studyhours;unhappiest = i + 1;}}}printf("%d\n", unhappiest);}return 0; }
0 0
- POJ 2656 解题报告
- poj数百篇解题报告
- poj 1141解题报告
- poj 1001解题报告
- poj 1011 解题报告
- poj 1087 解题报告
- poj 2153解题报告
- poj 2051解题报告
- POJ 1167 解题报告
- poj 1026 解题报告
- POJ 1077 解题报告
- POJ 1042 解题报告
- POJ 1095 解题报告
- POJ 1159解题报告
- poj 2312解题报告
- POJ 1001解题报告
- POJ 1002解题报告
- POJ 1006解题报告
- Unity5 Assetbundle简单使用 及 打包Material文件超大的问题
- Ubuntu 教程 - 更改 Ubuntu 使用语言
- unix网络编程常见问题总结
- vs2012下编译ezrgb24所想
- __stdcall与__cdecl的区别
- POJ 2656 解题报告
- 轻松搞定面试中的二叉树题目
- java 源码学习方法
- __stdcall的故事版解释
- Java学习之Iterator(迭代器)的一般用法 (转)
- 面试收藏的博客
- iTunes 备份损坏的解决办法
- 边学习边实践才是硬道理=a=
- Win7/Vista Hook CreateProcess 的特别之处