A. 挑战 时间限制: 1.0 秒 空间限制: 512 MB 原题地址 题目描述 企鹅豆豆在玩一款叫做 Slay the spire 的游戏。为了简化游戏,我们将游戏规则魔改如下: 主角一开始血量为 HH,游戏里一共有 NN 个房间,每个房间里有一些怪物,第 ii 个房间需要受到 DiDi 的伤害才 ...
分类:
其他好文 时间:
2020-11-01 09:55:56
阅读次数:
18
https://codeforces.com/problemset/problem/1436/D 这题就是让村名尽可能集中在叶子上,但是可能叶子上本来就有很多村民,就是这样。 假设 1. mx[x]为在x点可以抓到的最多的人 2. chal[x]为 在x点还差chal[x]人就可以让x下面所有叶子都 ...
分类:
其他好文 时间:
2020-10-31 01:31:44
阅读次数:
13
leetcode_easy_array problem 1486. XOR Operation in an Array solution #1: code: 参考 1. leetcode_1486. XOR Operation in an Array; 完 ...
分类:
其他好文 时间:
2020-10-30 12:53:24
阅读次数:
17
题目 题目链接:https://codeforces.com/problemset/problem/468/B 给出 \(n\) 个各不相同的数字,将它们分别放入 \(A\) 和 \(B\) 两个集合中,使它们满足: 若数字 \(x\) 在集合 \(A\) 中,那么数字 \(a-x\) 也在集合 \ ...
分类:
其他好文 时间:
2020-10-30 12:08:18
阅读次数:
14
在网友的国度中共有?n?种不同面额的货币,第?i?种货币的面额为?a[i],你可以假设每一种货币都有无穷多张。 为了方便,我们把货币种数为?n、面额数组为?a[1..n]?的货币系统记作?(n,a)。 在一个完善的货币系统中,每一个非负整数的金额?x?都应该可以被表示出,即对每一个非负整数?x,都存 ...
分类:
其他好文 时间:
2020-10-29 10:47:05
阅读次数:
40
use 3D version to calculate how much water the model can contain this problem need use dfs,from the edge part which mustn't be answer,for the edge can ...
分类:
移动开发 时间:
2020-10-29 10:06:29
阅读次数:
25
一.题源 https://www.lintcode.com/problem/permutations-ii/description https://leetcode-cn.com/problems/permutations-ii/ 二.代码分析 1 public class Solution { 2 ...
分类:
其他好文 时间:
2020-10-27 11:42:13
阅读次数:
24
Problem Description 人称“AC女之杀手”的超级偶像LELE最近忽然玩起了深沉,这可急坏了众多“Cole”(LELE的粉丝,即"可乐"),经过多方打探,某资深Cole终于知道了原因,原来,LELE最近研究起了著名的RPG难题: 有排成一行的n个方格,用红(Red)、粉(Pink)、 ...
分类:
其他好文 时间:
2020-10-26 11:29:27
阅读次数:
26
题目介绍 给定正整数n,利用1到n构造所有可能的二叉树,并返回。 Example: Input: 3 Output: [ [1,null,3,2], [3,2,null,1], [3,1,null,null,2], [2,1,3], [1,null,2,null,3] ] Explanation: ...
分类:
其他好文 时间:
2020-10-26 11:19:06
阅读次数:
17
Reference: [Dockerfile Security Best Practices] Container security is a broad problem space and there are many low hanging fruits one can harvest to m ...
分类:
其他好文 时间:
2020-10-24 11:48:16
阅读次数:
37