crossing self hard 335

741. 摘樱桃 (Hard)

问题描述 741. 摘樱桃 (Hard) 给你一个 n x n 的网格 grid ,代表一块樱桃地,每个格子由以下三种数字的一种来表示: 0 表示这个格子是空的,所以你可以穿过它。 1 表示这个格子里装着一个樱桃,你可以摘到樱桃然后穿过它。 -1 表示这个格子里有荆棘,挡着你的路。 请你统计并返回: ......
樱桃 Hard 741

741. Cherry Pickup (Hard)

Description 741. Cherry Pickup (Hard) You are given an n x n grid representing a field of cherries, each cell is one of three possible integers. 0 mea ......
Cherry Pickup Hard 741

Codeforces Round 881 (Div. 3) F2. Omsk Metro (hard version) (线段树 )

[传送门](https://codeforces.com/contest/1843/problem/F2) 大致题意: ** 动态给定一颗树,树上每个结点的权值一定为1或者-1。最开始有1号点,权值为1。** ** 输入n表示有n个操作,当第一个符号为+ a b表示添加结点操作,编号依次递增。a表示 ......
线段 Codeforces version Round Metro

1595. 连通两组点的最小成本 (Hard)

问题描述 1595. 连通两组点的最小成本 (Hard) 给你两组点,其中第一组中有 size₁ 个点,第二组中有 size₂ 个点,且 size₁ >= size₂ 。 任意两点间的连接成本 cost 由大小为 size₁ x size₂ 矩阵给出,其中 cost[i][j] 是第一组中的点 i ......
成本 1595 Hard

1595. Minimum Cost to Connect Two Groups of Points] (Hard)

Description 1595. Minimum Cost to Connect Two Groups of Points (Hard) You are given two groups of points where the first group has size1 points, the s ......
Minimum Connect Groups Points 1595

CF958C3. Encryption (hard)

谁说 $n\le5\times 10^5$,$k\le100$,$p\le100$ 只能 $O(nk)$?我今天就要用 $O(nk\log p)$ 过这个题! 定义 $f_{i,j}$ 表示前 $j$ 个数,分成 $i$ 段的最小价值和,$s_i$ 表示前缀和(对 $p$ 取模),转移就是 $f_{ ......
Encryption hard 958 CF C3

Time Interval Aware Self-Attention for Sequential Recommendation

[TOC] > [Li J., Wang Y., McAuley J. Time interval aware self-attention for sequential recommendation. WSDM, 2020.](https://dl.acm.org/doi/10.1145/3336 ......

1494. 并行课程 II (Hard)

问题描述 1494. 并行课程 II (Hard) 给你一个整数 n 表示某所大学里课程的数目,编号为 1 到 n ,数组 relations 中, relations[i] = [xᵢ, yᵢ] 表示一个先修课的关系,也就是课程 xᵢ 必须在课程 yᵢ 之前上。同时你还有一个整数 k 。 在一个学 ......
课程 1494 Hard II

1494. Parallel Courses II (Hard)

Description 1494. Parallel Courses II (Hard) You are given an integer n, which indicates that there are n courses labeled from 1 to n. You are also gi ......
Parallel Courses 1494 Hard II

552.Student Attendance Record II (Hard)

Description 552. Student Attendance Record II (Hard) An attendance record for a student can be represented as a string where each character signifies ......
Attendance Student Record Hard 552

1483. Kth Ancestor of a Tree Node (Hard)

Description 1483. Kth Ancestor of a Tree Node (Hard) You are given a tree with n nodes numbered from 0 to n - 1 in the form of a parent array parent w ......
Ancestor 1483 Hard Tree Node

Python - 方法参数中,带self和不带self的区别

不带self 该python文件中,没有类的概念。因此所有的方法参数中,没有self #文件名 solution.py def partition(head: Optional[ListNode], x: int) -> Optional[ListNode]: #... if __name__ == ......
self 参数 方法 Python

[ABC162E] Sum of gcd of Tuples (Hard)

## 题面翻译 给定$n,k$,求 $$\sum^k_{a_1=1}\sum^k_{a_2=1}\sum^k_{a_3=1}\dots\sum^k_{a_n=1}gcd(a_1,a_2,a_3,\dots,a_n)\ mod\ 1000000007$$ ### 制約 - $ 2\ \leq\ N\ ......
Tuples 162E Hard of ABC

cross socket ICrossHttpServer

cross socket ICrossHttpServer cross socket是delphi跨平台的一个socket库。 /// <author>cxg 2023-2-12</author> /// TStream(ARequest.body),auto be free unit sock.C ......
ICrossHttpServer socket cross

vite 本地代理请求https接口 self signed certificate 自签名证书错误

### vite本地代理后端接口为https时,无法发送请求,并报错如下: ![image](https://img2023.cnblogs.com/blog/1857566/202306/1857566-20230614155931692-1367583313.png) ### 查询vite文档, ......
certificate 接口 证书 错误 signed

2681. 英雄的力量 (Hard)

问题描述 2681. 英雄的力量 (Hard) 给你一个下标从 0 开始的整数数组 nums ,它表示英雄的能 力值。如果我们选出一部分英雄,这组英雄的 力量 定义为: i₀ , i₁ ,... iₖ 表示这组英雄在数组中的下标。那么这组英雄的力量为 max(nums[i₀],nums[i₁] .. ......
力量 英雄 2681 Hard

297.二叉树的序列化与反序列化 (Hard)

问题描述 297. 二叉树的序列化与反序列化 (Hard) 序列化是将一个数据结构或者对象转换为连续的比特位的操作,进而可以将转换后的数据存储在一个文件或者内存中,同时也可以通过网络传输到另一个计算机环境,采取相反方式重构得到原数据。 请设计一个算法来实现二叉树的序列化与反序列化。这里不限定你的序列 ......
序列 Hard 297

84. 柱状图中最大的矩形 (Hard)

问题描述 84. 柱状图中最大的矩形 (Hard) 给定 n 个非负整数,用来表示柱状图中各个柱子的高度。每个柱子 彼此相邻,且宽度为 1 。 求在该柱状图中,能够勾勒出来的矩形的最大面积。 示例 1: ![](https://assets.leetcode.com/uploads/2021/01/ ......
矩形 Hard 84

41.缺失的第一个正数 (Hard)

问题描述 41. 缺失的第一个正数 (Hard) 给你一个未排序的整数数组 nums ,请你找出其中没有出现的最小的正整数。 请你实现时间复杂度为 O(n) 并且只使用常数级别额外空间的解决方案。 示例 1: 输入:nums = [1,2,0] 输出:3 示例 2: 输入:nums = [3,4,- ......
正数 缺失 Hard 41

2646. 最小化旅行的价格总和 (Hard)

问题描述 2646. 最小化旅行的价格总和 (Hard) 现有一棵无向、无根的树,树中有 n 个节点,按从 0 到 n - 1 编号。给你一个整数 n 和一个长度为 n - 1 的二维整数数 组 edges ,其中 edges[i] = [aᵢ, bᵢ] 表示树中节点 aᵢ 和 bᵢ 之间存在一条边 ......
总和 价格 2646 Hard

85. 最大矩形 (Hard)

问题描述 85. 最大矩形 (Hard) 给定一个仅包含 0 和 1 、大小为 rows x cols 的二维二进 制矩阵,找出只包含 1 的最大矩形,并返回其面积。 示例 1: ![](https://assets.leetcode.com/uploads/2020/09/14/maximal.j ......
矩形 Hard 85

1483. 树节点的第 K 个祖先 (Hard)

问题描述 1483. 树节点的第 K 个祖先 (Hard) 给你一棵树,树上有 n 个节点,按从 0 到 n-1 编号。树以父节点数组的形式给出,其中 parent[i] 是节点 i 的父节点。树的根节点是编号为 0 的节点。 树节点的第 k个祖先节点是从该节点到根节点路径上的第 k 个节点。 实现 ......
节点 祖先 1483 Hard

send it failed() The virtual circuit was reset by the remote side executing a hard or abortive close. (连接被对方重置)

串口调试助手报错提示 The virtual circuit was reset by the remote side executing a hard or abortive close. for upd socket ,the remote host was unable to deliver ......
executing abortive 对方 circuit virtual

KingbaseES数据库改写SQL Server数据库CROSS APPLY和OUTER APPLY

一、功能介绍: CROSS APPLY和OUTER APPLY是SQL Server中的一种连接操作,类似于JOIN语句可以将一张表与一个表函数或一个子查询进行关联。表函数是一种返回一个表类型的数据的函数,子查询是一个嵌套在外部查询中的查询。它们可以与表值函数或子查询配合使用,返回左表和右表的匹配结 ......
数据库 数据 APPLY KingbaseES Server

Attention、Self-Attention 与 Multi-Head Attention

Corpus语料库与DB数据库 World Knowledge世界常识库:OALD牛津高阶/Synonyms/Phrases/…, 新华字典/成语词典/辞海, 行业词典,大英百科,Wikipedia,… 全局信息: Corpus语料库、行业通用数据库(例如Springer/Google Schola ......

业务场景(用户交互) + Corpus语料库/数据库建立 + Attention 与 Self-Attention:世界常识库|全局信息|语法信息|句法信息|Context上下文信息

一、场景(用户交互): 1. 用户发起新会话Session,初始化交互系统,等待 用户输入 或 传入任务文档; 2. 用户实时输入,触发实时交互,设当前输入句子为S: 当前输入句子 S 长度未定,并且可能是动态字符流式输入: 因此可以用 Sliding Window滑动窗口, 提取 当前输入单词Wo ......
信息 Attention 语料库 语料 句法

[ABC166E] This Message Will Self-Destruct in 5s

[This Message Will Self-Destruct in 5s の 传送门](https://www.luogu.com.cn/problem/AT_abc166_e) ## Solution 首先看到 > $j-i=A_i+A_j$ 转换一下,$i+a_i=j-a_j$。 接下来,对 ......
Self-Destruct Destruct Message 166E This

原生AJAX案例浏览器报错:Cross origin requests are only supported for protocol

报错信息如下: 代码如下: <!DOCTYPE html> <html> <body> <div id="demo"> <h1>XMLHttpRequest 对象</h1> <button type="button" onclick="loadDoc()">更改内容</button> </div> ......
supported requests protocol 浏览器 案例

CF1559D2 Mocha and Diana (Hard Version) 题解

[Luogu](https://www.luogu.com.cn/problem/CF1559D2) | [Codeforces](https://codeforces.com/problemset/problem/1559/D2) ### 题意 给定两个森林 $A$ 和 $B$,均有编号 $1$ ......
题解 Version 1559D Mocha Diana

Error系列-unexpected error occurred self signed certificate in certificate chain

## 执行yarn install 或者 其他命令遇到这个报错: error An unexpected error occurred: "https://XXX/XXX self signed certificate in certificate chain". ``` XXX cloud-ser ......
certificate unexpected occurred signed Error