用线段树维护区间剩余的最大值,这样可以辅助二分,越左越好 对于用完k堆的,直接将他的值变为0即可 #include<bits/stdc++.h> using namespace std; typedef long long ll; const int N=6e5+10; struct node{ i ...
分类:
其他好文 时间:
2020-07-07 23:39:52
阅读次数:
91
class Try_StructClass { public void Test() { Number a = 1; Number b = a; a = 2; WriteLine($"a={a}, b={b}"); //a=2, b=1 Text A = 1; Text B = A; A = 2; ...
# 今日内容 1. 数据库的基本概念 2. MySQL数据库软件 1. 安装 2. 卸载 3. 配置 3. SQL ## 数据库的基本概念 1. 数据库的英文单词: DataBase 简称 : DB 2. 什么数据库? * 用于存储和管理数据的仓库。 3. 数据库的特点: 1. 持久化存储数据的。其 ...
分类:
数据库 时间:
2020-07-07 20:02:09
阅读次数:
88
下面是用翻译软件翻译的 5. Using OBEX over IrDA Ultra-Lite (Connectionless use) OBEX is constructed to take advantage of(利用。。。的优点) the benefits of a connection-or ...
分类:
其他好文 时间:
2020-07-07 19:37:47
阅读次数:
59
树上主席树。 题意要求求u-v的路径上,前k小个数字是多少。转换一下,每次求1-k小的数字。故我们想到了树上主席树。 基于树上点前缀和的特点有:$sum[u]+sum[v]-sum[lca]-sum[fa[lca]]$是u-v路径的和。我们基于此,使用主席树,每个子树是权值线段树。就可以使用前缀和的 ...
分类:
其他好文 时间:
2020-07-07 17:35:54
阅读次数:
57
from pyspark.sql import SparkSession,Rowfrom pyspark.sql.types import StructField, StructType, StringType, IntegerType, LongType data = [('Alex','male ...
分类:
其他好文 时间:
2020-07-07 15:40:28
阅读次数:
55
public struct Complex { public double real; public double imaginary; public Complex(double real, double imaginary) { this.real = real; this.imaginary ...
分类:
其他好文 时间:
2020-07-07 13:25:18
阅读次数:
57
#Reverse ##内涵 0707 直接拖进IDA看到疑似flag,按A可以转中文 A ASCII解析成ASCII ##[BJDCTF 2nd]guessgame 拖进IDA 发现flag ##xor 拖进IDA int __cdecl main(int argc, const char **ar ...
分类:
其他好文 时间:
2020-07-07 11:39:50
阅读次数:
87
方法1:递归 /** * Definition for a binary tree node. * struct TreeNode { * int val; * struct TreeNode *left; * struct TreeNode *right; * }; */ bool hasPath ...
分类:
其他好文 时间:
2020-07-07 10:22:49
阅读次数:
60
题目来源:leetcode104 二叉树的最大深度 题目描述: 给定一个二叉树,找出其最大深度。 二叉树的深度为根节点到最远叶子节点的最长路径上的节点数。 说明: 叶子节点是指没有子节点的节点。 示例: 给定二叉树 [3,9,20,null,null,15,7] 返回它的最大深度 3 。 解题思路: ...
分类:
其他好文 时间:
2020-07-07 10:18:52
阅读次数:
80