注册一亩三分地论坛,查看更多干货!
您需要 登录 才可以下载或查看附件。没有帐号?注册账号 
x
新人求米!
1. There are N empty glasses with a capacity of 1, 2, ..., N liters (there is exactly one glass of each unique capacity). You want to pour exactly K liters of water into glasses. Each glass may be either full or empty (a glass cannot be partially filled).
What is the minimum number of glasses tfunction:
class Solution & public int solution(int|] A); )
that, given an array A of N integers, returns the maximum sum of numbers that can be covered using at most three tiles. |