You are trapped in a 3D dungeon and need to find the quickest way out! The dungeon is composed of unit cubes which may or may not be filled with rock. ...
分类:
其他好文 时间:
2020-03-22 19:57:31
阅读次数:
68
题目链接:http://poj.org/problem?id=2718 题意: 将所给出的所有数字排列组合生成两个数,使其差的绝对值最小。求最小值。 这是一道穷竭搜索类型的题目,难度不大,还学到了 next_permutation 函数, 写好了一个代码后提交却是TLE!太搞人心态了,修改后有时报错 ...
分类:
其他好文 时间:
2020-03-22 19:33:31
阅读次数:
75
贪心,有一些点少不留意就会wa #include <iostream> #include <cstdio> #include <cstring> #include <limits> //#include <stack> #include<queue> #include <algorithm> #de ...
分类:
其他好文 时间:
2020-03-21 21:43:42
阅读次数:
64
结构体+优先队列+贪心 #include <iostream> #include <cstdio> #include <cstring> #include <limits> //#include <stack> #include<queue> #include <algorithm> #define ...
分类:
其他好文 时间:
2020-03-21 21:23:32
阅读次数:
65
并查集+贪心 https://vjudge.net/contest/362147#problem/C #include <iostream> #include <cstdio> #include <cstring> #include <limits> #include <algorithm> #de ...
分类:
其他好文 时间:
2020-03-21 20:56:28
阅读次数:
60
在一个给定形状的棋盘(形状可能是不规则的)上面摆放棋子,棋子没有区别。要求摆放时任意的两个棋子不能放在棋盘中的同一行或者同一列,请编程求解对于给定形状和大小的棋盘,摆放k个棋子的所有可行的摆放方案C。 Input 输入含有多组测试数据。每组数据的第一行是两个正整数,n k,用一个空格隔在一个n*n的 ...
分类:
其他好文 时间:
2020-03-21 16:19:43
阅读次数:
50
描述:https://www.luogu.com.cn/problem/P3467 1.考虑如果整个建筑物链是等高的,一张高为链高,宽为整个建筑物宽的海报即可完全覆盖; 2.若有两个不等高的元素组成建筑物链,那么一定需要两张; 3.因为题目要求海报不可超出建筑物链,那么我们即可用单调栈维护:初始海报 ...
分类:
其他好文 时间:
2020-03-21 13:11:06
阅读次数:
63
"Link" 题意: 给定一张 $N M(2 \le n,m \le 200)$ 的矩形网格纸,两名玩家轮流行动。 在每一次行动中,可以任选一张矩形网格纸,沿着某一行或某一列的格线,把它剪成两部分。 首先剪出 $1 1$ 的格纸的玩家获胜。 两名玩家都采取最优策略行动,求先手是否能获胜。 思路: 得 ...
分类:
其他好文 时间:
2020-03-21 10:03:35
阅读次数:
48
1、properties:读取文件信息 (1)jdbc配置文件: jdbc.driver=com.mysql.jdbc.Driver jdbc.url=jdbc:mysql://localhost:3306/stu_mangement jdbc.username=root jdbc.password ...
分类:
移动开发 时间:
2020-03-20 12:29:48
阅读次数:
92
Codeforces Round #622 (Div. 2) C2. Skyscrapers (hard version) 题意: 你是一名建筑工程师,现给出 n 幢建筑的预计建设高度,你想建成峰状,如: 1 2 3 2 1 → 1 2 3 2 1 1 2 3 1 2 → 1 2 3 1 1 8 1 ...
分类:
其他好文 时间:
2020-03-19 21:25:05
阅读次数:
52