poj 2709 贪心
来源:互联网 发布:网络小祖宗是什么意思 编辑:程序博客网 时间:2024/04/28 20:25
import java.util.Arrays;import java.util.Scanner;public class Main2709 {static int Gray=0;public static void main(String[] args) {Scanner in=new Scanner(System.in);while(in.hasNext()){int nCase=in.nextInt();if(nCase==0)break;int max=0;Integer[] array=new Integer[nCase];for(int i=0;i<nCase;i++){array[i]=in.nextInt();}Gray=in.nextInt();for(;Gray>0;Gray--){Arrays.sort(array);array[0]++;array[1]++;array[2]++;}for(int i=0;i<nCase;i++){if(array[i]>max)max=array[i];}int box=max/50;if(box*50<max)box++;System.out.println(box);}}}
- poj 2709 贪心
- POJ | 2709 Painter | 贪心
- POJ 2709 Painter 贪心
- poj 2709 贪心 painter
- poj 2709 Painter (贪心)
- POJ--2709:Painter (贪心)
- poj 2709 贪心问题
- poj 2709 贪心
- POJ 2709-Painters 贪心问题
- poj 2709 Painter(贪心)
- poj 2709 贪心暴搜
- POJ-2709-Painter(贪心)
- POJ 2709 Painter 贪心详解
- POJ 2709 颜料盒数量 贪心法
- poj 2709 Painter 坑爹贪心
- POJ—2709—Painter—【贪心】
- POJ 2709 贪心算法 测试数据生成程序
- POJ 2709 混合颜料 acm 贪心
- Oracle 数据库开发 面试试题
- poj3112
- Android支持的媒体格式
- Js操作Cookie,保持页面刷新(需要用到jquery.js文件)
- Linux 防火墙iptables 学习笔记(五)linux+iptables构筑防火墙实例
- poj 2709 贪心
- linux_sound_alsa_Android+alsa音频系统中的几个问题
- 系统调用的理解
- linux_sound_alsa_ALSA体系SOC子系统中数据流分析
- opengl中局部坐标和全局坐标之我的理解
- linux_sound_alsa_ALSA体系SOC子系统中hw_params逻辑
- 黑马程序员——交通灯项目思路
- 关于javap的研究
- 创业者都在纠结和困惑些啥?