搜索结果
查询Tags标签: water,共有 13条记录-
LeetCode Container With Most Water 区间贪心
You are given an integer array height of length n. There are n vertical lines drawn such that the two endpoints of the ith line are (i, 0) and (i, height[i]). Find two lines that together with the x-axis form a container, such that the container conta…
2022/7/10 23:53:15 人评论 次浏览 -
二维接雨水
https://leetcode.cn/problems/trapping-rain-water-ii/ func trapRainWater(heightMap [][]int) int {m, n := len(heightMap), len(heightMap[0])maxHeight := 0for _, row := range heightMap {//找到最高的格子for _, h := range row {maxHeight = max(maxHeight, h)}…
2022/6/20 23:21:35 人评论 次浏览 -
cement
A cement is a binder, a substance used for construction that sets, hardens, and adheres to other materials to bind them together. Cement is seldom used on its own, but rather to bind sand and gravel (aggregate) together. Cement mixed with fine aggrega…
2022/4/22 6:16:42 人评论 次浏览 -
Water 2.5.9 发布,一站式服务治理平台
Water(水孕育万物...) Water 为项目开发、服务治理,提供一站式解决方案(可以理解为微服务架构支持套件)。基于 Solon 框架开发,并支持完整的 Solon Cloud 规范;已在生产环境奔跑了4年。 功能约等于:consul + rabbitmq + elk + prometheus + openFaas + quartz 等一…
2022/4/9 23:19:58 人评论 次浏览 -
烘干衣服(二分策略)
DescriptionIt is very hard to wash and especially to dry clothes in winter. But Jane is a very smart girl. She is not afraid of this boring process. Jane has decided to use a radiator to make drying faster. But the radiator is small, so it can hold on…
2022/3/4 6:15:08 人评论 次浏览 -
《程序设计基础》 综合程序设计 7-1 自动售货机 (30 分)
如图所示的简易自动售货机,物品架1、2上共有10样商品,按顺序进行编号分别为1-10,标有价格与名称,一个编号对应一个可操作按钮,供选择商品使用。如果物架上的商品被用户买走,储物柜中会自动取出商品送到物架上,保证物品架上一定会有商品。用户可以一次投入较多钱币…
2022/1/30 20:04:36 人评论 次浏览 -
Python数据类型-string
string,number,list,dict,set,tumple string字符串换行,如 str="heffer \n" \ "aaa\n" \ str1=dddd aaaa 切片格式 变量名[开始索引值:结束索引值:步长] 特殊字符处理 \n \ r/R(原字符输出) r"112323/n"一、string类型 1.常用的内置函数…
2021/11/5 12:09:40 人评论 次浏览 -
Python数据类型-string
string,number,list,dict,set,tumple string字符串换行,如 str="heffer \n" \ "aaa\n" \ str1=dddd aaaa 切片格式 变量名[开始索引值:结束索引值:步长] 特殊字符处理 \n \ r/R(原字符输出) r"112323/n"一、string类型 1.常用的内置函数…
2021/11/5 12:09:40 人评论 次浏览 -
[Leetcode 11]容器中装最多的水Container With Most Water
【题目】 木桶短板,能装的最多水,由最短的那条决定 Given n non-negative integers a1, a2, ..., an , where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two endpoints of the line i is at (i, ai) and (i, 0). Find …
2021/8/23 23:36:41 人评论 次浏览 -
[Leetcode 11]容器中装最多的水Container With Most Water
【题目】 木桶短板,能装的最多水,由最短的那条决定 Given n non-negative integers a1, a2, ..., an , where each represents a point at coordinate (i, ai). n vertical lines are drawn such that the two endpoints of the line i is at (i, ai) and (i, 0). Find …
2021/8/23 23:36:41 人评论 次浏览 -
[LeetCode] 778. Swim in Rising Water
On an N x N grid, each square grid[i][j] represents the elevation at that point (i,j). Now rain starts to fall. At time t, the depth of the water everywhere is t. You can swim from a square to another 4-directionally adjacent square if and only if the…
2021/6/21 6:26:04 人评论 次浏览 -
Thinkphp实现图片水印平铺效果
图水印平铺,有需要的了解一下 调用图片水印平铺代码 use think\Image; class .... public function test(){$image = Image::open(bg.jpg);// 给原图设置水印图片(colleced.png)并保存water_image.png$image->tilewater(colleced.png,100)->save(water_image.png…
2021/5/21 14:24:50 人评论 次浏览 -
A. Potion-making
A. Potion-making You have an initially empty cauldron, and you want to brew a potion in it. The potion consists of two ingredients: magic essence and water. The potion you want to brew should contain exactly k % magic essence and (100−k) % water. In …
2021/5/16 18:26:02 人评论 次浏览