摘要: 这道题就是苹果数一定的情况下,能不能满足一定数量孩子的胃口。(这里可以参见上一个博文)典型的贪心算法。 class Solution { public boolean canPlaceFlowers(int[] flowerbed, int n) { int count=0; for(int i=0 阅读全文
posted @ 2020-05-12 18:04 我是SSP 阅读(275) 评论(0) 推荐(0) 编辑