2023 ICPC Asia EC网络预选赛第一场赛题

news2024/12/23 13:07:57

2023 ICPC Asia EC

文章目录

  • 2023 ICPC Asia EC Online Qualifier Round 1
    • A Qualifiers Ranking Rules
    • B String
    • C Multiply Then Plus
    • D Transitivity
    • E Magical Pair
    • F Alice and Bob
    • G Spanning Tree
    • H Range Periodicity Query
    • I Pa?sWorD
    • J Minimum Manhattan Distance
    • K Minimum Euclidean Distance
    • L KaChang!
  • 声明

2023 ICPC Asia EC Online Qualifier Round 1

A Qualifiers Ranking Rules

The following is the current ranking rules for the ICPC Asia EC Online Qualifiers, and there will be two online contests.

  1. In each contest, only the rank of the top-ranked team from each university will be taken as the score of that university;
  2. In each contest, participating universities will be ranked according to their scores;
  3. The two rankings of universities are combined using the merge sorting method. For any two universities that obtain the same ranking in different contests, the university that received this ranking in the first contest will be ranked first.
  4. Delete duplicate universities and obtain the final ranking of all participating universities (only the highest rankings for each university are retained).
    Now assuming that there are n teams in the first contest and m teams in the second contest.
    For each contest, given the ranking of each team and the university to which it belongs, please output the final ranking of all participating universities according to the above rules.
    You can better understand this process through the sample.

Input
The first line contains two integers n,m (1≤n,m≤104) , representing the number of teams participating in the first contest and the second contest.
Then following n lines, the i-th line contains a string si (1≤∣si∣≤10) only consisting of uppercase letters, representing the abbreviation of the university to which the i-th ranked team in the first contest belongs.
Then following m lines, the i-th line contains a string ti (1≤∣ti∣≤10) only consisting of uppercase letters, representing the abbreviation of the university to which the i-th ranked team in the second contest belongs.
It’s guaranteed that each university has only one abbreviation.
Output
Output several lines, the i-th line contains a string, representing the abbreviation of the i-th ranked university in the final ranking.
You should ensure that the abbreviation of any participating universities appears exactly once.
Input Sample

14 10
THU
THU
THU
THU
XDU
THU
ZJU
THU
ZJU
THU
NJU
WHU
THU
HEU
PKU
THU
PKU
PKU
ZJU
NUPT
THU
NJU
CSU
ZJU

Output Sample

THU
PKU
XDU
ZJU
NJU
NUPT
WHU
HEU
CSU

Hint
Sample is part of the results in 2022 ICPC Asia EC Online Contest.
In the first contest, the ranking of the universities is:

THU
XDU
ZJU
NJU
WHU
HEU

In the second contest, the ranking of the universities is:

PKU
THU
ZJU
NUPT
NJU
CSU

By combining these two rankings according to the rules, the rankings of the universities is:

THU
PKU
XDU
THU
ZJU
ZJU
NJU
NUPT
WHU
NJU
HEU
CSU

By deleting duplicate universities we will get the final ranking.

代码长度限制
16 KB
时间限制
1000 ms
内存限制
128 MB

B String

Given two strings S1 and S2 of equal length (indexed from 1).
Now you need to answer q queries, with each query consists of a string T.
The query asks how many triplets of integers (i,j,k) (1≤i≤j<k≤∣S1∣) satisfy the condition S1[i,j]+S2[j+1,k]=T.
Here S[l,r] denotes the substring of S with index form l to r, and “+” denotes concatenation of strings.
Input
The first line contains a string S1 .
The second line contains a string S2 .
It is guaranteed that 1≤∣S1∣=∣S2∣≤105.
The third line contains a positive integer q (1≤q≤2×105), representing the number of queries.
The next q lines each contain a string T (1≤∣T∣≤2×105), representing the query strings.
It is guaranteed that ∑∣T∣≤2×105 and all the strings input only consisting of lowercase letters.
Output
For each query, output a line with a positive integer representing the number of triplets that satisfy the condition.
Input Sample

aaababaa
aababbca
7
aa
abb
aab
ab
abc
bb
ba

Output Sample

3
1
3
2
2
1
0
代码长度限制
16 KB
时间限制
1000 ms
内存限制
256 MB

C Multiply Then Plus

Given n pairs (a1,b1),(a2,b2),…,(an,bn), you need to perform q operations.
Each operation has one of the following forms:
• 1 k a b (1≤k≤n, 1≤a,b≤109): Modify the k-th pair into (a,b).
• 2 x l r (1≤x≤109, 1≤l≤r≤n): Find the maximum value of ai×x+bi, where l≤i≤r.
Input
The first line contains two integers n and q (1≤n,q≤500000) denoting the number of pairs and the number of operations.
Each of the following n lines contains two integers ai and bi (1≤ai,bi≤109), denoting the i-th pair.
Each of the next q lines describes an operation in the format shown above.
Output
For each query, print a single line containing an integer denoting the answer.
Sample Input

3 5
2 3
1 5
3 1
2 1 1 3
2 3 1 2
1 3 1 1
2 3 3 3
2 2 1 3

Sample Output

6
9
4
7
代码长度限制
16 KB
时间限制
6000 ms
内存限制
1024 MB

D Transitivity

Given a simple undirected graph with n vertices and m edges, and it’s guaranteed that m<2n(n−1) .
We define an undirected graph to be transitive if and only if for any two different vertices u,v :
If there exists a path starting from u and ending at v in the graph, then there should exists an edge connected u and v in the graph.
Now you should add some undirected edges to the graph (add at least one edge). You need to ensure that after adding edges, the graph is still a simple undirected graph and is transitive.
The question is, how many edges need to be added at least?
Recall that a simple undirected graph is an undirected graph that does not have more than one edge between any two vertices and no edge starts and ends at the same vertex.
Input
The first line contains two integers n,m (3≤n≤106,1≤m≤min(106,2n(n−1)−1)), indicating the number of vertices and edges in the given graph.
Then the following m lines, each line contains two integers u,v (1≤u,v≤n,u=v) , indicating an edge in the given graph. It’s guaranteed that the graph is simple.
Output
A single positive integer, representing the minimum number of edges you need to add.
Input Sample

4 3
1 2
1 3
2 3

Output Sample

3
代码长度限制
16 KB
时间限制
1000 ms
内存限制
128 MB

E Magical Pair

For a prime number n, if a pair of positive integers (x,y) satisfies the congruence relation: xy≡yx(modn). Then we consider (x,y) to be magical.
We want to know how many ordered pairs of positive integers (x,y) are magical for a given prime number n, where 0<x,y≤n2−n. Since the answer could be large, we will output it modulo 998244353.
Input
The first line input a positive integer T (1≤T≤10), which represents the total number of test cases.
Then for each test case, input a single line with a prime number n (2≤n≤1018), and it’s guaranteed that n−1 is not a multiple of 998244353.
Output
Output T lines, each containing an integer representing the result modulo 998244353.
Input Sample 1

5
5
11
67
97
101

Output Sample 1

104
1550
479886
1614336
1649000

Input Sample 2

6
998244353
998244853
19260817
1000000007
1000000009
350979772330483783

Output Sample 2

284789646
90061579
971585925
887008006
527110672
334479293
代码长度限制
16 KB
时间限制
1000 ms
内存限制
512 MB

F Alice and Bob

You are watching Alice and Bob playing a game.
The game is played on an array of length n. Alice and Bob take turns in action, Alice goes first.
In each turn, the current player can select two different numbers ai and aj in the array, and then change their values. Assume after changes the values of them are ai′ and aj′ , then an operation is legal if and only if ai+aj=ai′+aj′ and ∣ai′−aj′∣<∣ai−aj∣. Those who cannot perform legal operations lose.
After playing a few games, You decided to help Alice, because Alice, who was always overloaded when faced with a bunch of numbers, always unable to think in front of the genius Bob.
Before the start of each game, You will help Alice remove several numbers (could be 0) to reduce the burden on her brain, and you always leave exactly three numbers. And in order to give Alice a greater chance of winning, You will always leave Alice with a winning state, that is, there must be some kind of operating strategy that makes Alice must win no matter how Bob acts.
Now the question is how many ways there are to remove the numbers.
Two ways for removing numbers are considered different if and only if there exists an integer i (1≤i≤n) such that ai is not removed in one way and is removed in the other way.
Input
The first line contains a single integer T , representing the number of test cases.
Then follow the descriptions of each test case.
The first line contains an integer n(3≤n≤5×105) , which represents the number of numbers at the beginning.
The second line contains n integers a1,a2,a3,…,an(0≤ai≤1018), representing the original n numbers.
It’s guaranteed that ∑n≤3×106 .
Output
For each test case, output one integer in one line, indicating the number of different ways to remove numbers that satisfy the condition.
Input Sample

3
4
2 0 2 3
3
2 2 3
3
0 2 3

Output Sample

3
0
1

Hint
In the first test case, only removing a2 leaves a loser state.

代码长度限制
16 KB
时间限制
3000 ms
内存限制
512 MB

G Spanning Tree

We generate a spanning tree of n nodes according to the following random process:
Initially, there are no edges connecting the n nodes.
Then process the following n−1 operations:
• For the i-th operation, two integers ai and bi will be input, and it’s guaranteed that the two nodes are not connected before.
• Select a node ui from the connected block where ai is located with uniform probability, then select a node vi from the connected block where bi is located with uniform probability, and then add an edge to connect ui and vi .
It can be proved that no matter which two nodes are selected in each operation, after all operations are processed, a spanning tree of n nodes will be formed.
Now given a spanning tree of n nodes. What is the probability that the spanning tree formed by the random process is exactly this spanning tree?
You only need to output the value of the probability modulo 998244353 .
Please note that the probability could be 0, which means that you can never generate this spanning tree.
Input
The first line contains a single integer n (1≤n≤106) , representing the number of nodes.
For the following n−1 lines, each line contains two integers ai,bi (1≤ai,bi≤n,ai!=bi), representing the i-th operation, and it’s guaranteed that the two nodes are not connected before.
For the following n−1 lines, each line contains two integers ci,di (1≤ci,di≤n,ci!=di), representing an edge of the given spanning tree, and it’s guaranteed that the given edges forms a spanning tree.
Output
One line containing one integer, representing the value of the probability modulo 998244353 .
Input Sample

3
1 2
1 3
1 2
1 3

Output Sample

499122177
代码长度限制
16 KB
时间限制
1000 ms
内存限制

H Range Periodicity Query

For a string w=w1w2…wlen, we say that an integer p is a period of w if wi=wi+p holds for all i (1≤i≤len−p) and 1≤p≤len.
You will be given a string d=d1d2…dn to generate n+1 strings S0,S1,S2,…,Sn, where S0 is an empty string, and for all i (1≤i≤n) :
• When di is a lowercase English letter, Si=di+Si−1.
• When di is an uppercase English letter, assume its lowercase version is ci, then Si=Si−1+ci.
Here, ‘’+‘’ denotes concatenation of strings.
You will then be given a sequence of integers p1,p2,…,pm. You need to answer q queries, in each query, you will be given three integers k, l and r. You need to find the minimum number among pl,pl+1,…,pr−1,pr such that it is a period of string Sk, or determine there is no answer.
Input
The first line contains a single integer n (1≤n≤500000) denoting the number of non-empty strings.
The second line contains a string d of length n consists of lowercase and uppercase English letters.
The third line contains a single integer m (1≤m≤500000) denoting the length of the sequence p.
The fourth line contains m integers p1,p2,…,pm (1≤pi≤n).
The fifth line contains a single integer q (1≤q≤500000) denoting the number of queries.
Each of the next q lines contains three integers k, l and r (1≤k≤n, 1≤l≤r≤m), denoting a query.
Output
For each query, print a single line containing an integer denoting the answer. Note that when there is no answer, please print -1 instead.
Input Sample

7
AABAAba
9
4 3 2 1 7 5 3 6 1
6
1 4 4
2 1 4
2 1 3
3 3 5
5 4 7
7 8 9

Output Sample

1
1
2
-1
3
6
代码长度限制
16 KB
时间限制
2000 ms
内存限制
1024 MB

I Pa?sWorD

You need to log into a mysterious system, but you realize you’ve forgotten your password. The system does not support resetting password, so the only way to log in is to keep trying.
Fortunately, you still remember some information about the password:
Firstly, you are sure that the length of the password is n .
Then the information you remember can be described by a string s of length n.
let si represent the i-th character of s :
• if si is an uppercase letter or a digital character, then the i-th character of the password must be si;
• if si is an lowercase letter, then the i-th character of the password might be si or the uppercase form of si;
• if si is a question mark ? , then the i-th character of the password might be any uppercase letters, lowercase letters, and digital characters.
It’s guaranteed that the string s only contains uppercase letters, lowercase letters, digital characters, and question marks ?.
In addition, the system also has several requirements for passwords:
• At least one uppercase letter appears in the password;
• At least one lowercase letter appears in the password;
• At least one digital character appears in the password;
• Any two adjacent characters in the password cannot be the same.
Now you want to know, how many possible passwords are there? A possible password should fits both your memory and the system’s requirements, and it’s guaranteed that there exists at least one possible password.
You know that this answer will be very large, so you just need to calculate the result modulo 998244353 .
Please note the unusual memory limit.
Input
The first line contains a single integer n (3≤n≤105) , representing the length of the password .
The second line contains a string s with length n. It’s guaranteed that the string s only contains uppercase letters, lowercase letters, digital characters, and question marks ?.
It’s guaranteed that there exists at least one possible password.
Output
output a single line containing a single integer, representing the answer modulo 998244353.
Input Sample

4
a?0B

Output Sample

86
代码长度限制
16 KB
时间限制
1000 ms
内存限制
32 MB

J Minimum Manhattan Distance

Recall that on a two-dimensional plane, the Manhattan distance between two points (x1,y1) and (x2,y2) is ∣x1−x2∣+∣y1−y2∣, and the Euclidean distance between two points (x1,y1) and (x2,y2) is (x1−x2)2+(y1−y2)2. If both coordinates of a point are all integers, then we call this point an integer point.
Given two circles C1,C2 on the two-dimensional plane, and guaranteed the x-coordinates of any point in C1 and any point in C2 are different, and the y-coordinates of any point in C1 and any point in C2 are different.
Each circle is described by two integer points, and the segment connecting the two points represents a diameter of the circle.
Now you need to pick a point (x0,y0) inside or on the C2 such that minimize the expected value of the Manhattan distance from (x0,y0) to a point inside C1 , if we choose this point with uniformly probability among all the points with a real number coordinate inside C1.
Input
The first line contains a single integer t (1≤t≤105) , representing the number of test cases.
Then follow the descriptions of each test case.
The first line contains 4 integers x1,1,y1,1,x1,2,y1,2, representing the segment connecting (x1,1,y1,1) and (x1,2,y1,2) is a diameter of the circle C1.
The second line contains 4 integers x2,1,y2,1,x2,2,y2,2, representing the segment connecting (x2,1,y2,1) and (x2,2,y2,2) is a diameter of the circle C2.
All the coordinates input are integers in the range [−105,105] .
Output
For each test case, output a single line with a real number - the minimum expected Manhattan distance. Your answer will be considered correct if its absolute or relative error does not exceed 10−6. That is, if your answer is a, and the jury’s answer is b, then the solution will be accepted if max(1,∣b∣)∣a−b∣≤10−6 .
Input Sample

1
0 0 2 1
4 5 5 2

Output Sample

4.2639320225
代码长度限制
16 KB
时间限制
1000 ms
内存限制

K Minimum Euclidean Distance

One day you are surviving in the wild. After a period of exploration, you determine a safe area, which is a convex hull with n vertices P1,P2,…,Pn in counter-clockwise order and any three of them are not collinear.
Now you are notified that there will be q airdrop supplies, and for the i-th supply, its delivery range is described by a circle Ci , which means the supply will landed with uniformly probability among all the points with a real number coordinate inside Ci.
You need supplies so much that you decide to predetermine a starting point for each supply, and the starting point of two different supplies can be different. Every starting point should be inside the safe area and have the smallest expected value of the square of the Euclidean distance to the corresponding supply landing point.
Recall that On a two-dimensional plane, the Euclidean distance between two points (x1,y1) and (x2,y2) is (x1−x2)2+(y1−y2)2. If both coordinates of a point are all integers, then we call this point an integer point.
Input
The first line contains two integers n,q (3≤n,q≤5000) , representing the number of vertices of the safe area and the number of airdrop supplies.
The following n lines, each line contains two integers xi,yi , representing the coordinates of the i-th vertex of the safe area.
It’s garanteed that the vertices are given in counter-clockwise order and any three of them are not collinear.
Then the following q lines, each line contains 4 integers xi,1,yi,1,xi,2,yi,2, representing the segment connecting (xi,1,yi,1) and (xi,2,yi,2) is a diameter of the circle Ci.
All the coordinates input are integers in the range [−109,109] .
Output
For each airdrop supply, output a single line with a real number - the minimum expected value of the square of the Euclidean distance. Your answer will be considered correct if its absolute or relative error does not exceed 10−4. That is, if your answer is a, and the jury’s answer is b, then the solution will be accepted if max(1,∣b∣)∣a−b∣≤10−4 .
Input Sample

4 3
0 0 
1 0
1 1
0 1
0 0 1 1
1 1 2 2
1 1 2 3

Output Sample

0.2500000000
0.7500000000
1.8750000000
代码长度限制
16 KB
时间限制
2000 ms
内存限制128 MB

L KaChang!

Setting the time limit for algorithm competition questions is a very skillful task. If you set the time limit too tight, many people will scold you for being too demanding on details. On the other hand, if you set the time limit too loosely and allow an algorithm with unexpected time complexity to pass, then many people will scold you too.
When preparing problems, people usually set the time limit to at least twice the running time of the standard program, but sometimes contestants still feel that the time limit is too tight.
Now you have the standard program for a problem and another n programs considered “should pass the problem”. Given the running time of each program, please find the smallest integer k≥2, so that when the time limit is set to k times the running time of the standard program, all the provided programs can pass. A program can pass if and only if its running time less or equal to the time limit.
Input
The first line contains two integers n,T (1≤n,T≤105), representing the number of provided programs (not include the standard program), and the running time of the standard program.
The second line contains n integers t1,t2,…,tn (1≤ti≤109) , representing the running time of the provided programs.
Output
Output a single integer greater or equal to 2, representing the minimin k which could guarantee that all the provided programs can pass.
Input Sample

5 1000
998 244 353 1111 2333

Output Sample

3
代码长度限制
16 KB
时间限制
1000 ms
内存限制
128 MB

声明

本文是 2023 ICPC Asia EC网络预选赛第一场赛题,仅用作算法爱好者交流学习使用!侵删!

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/1021053.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

Openresty(二十二)ngx.balance和balance_by_lua终结篇

一 灰度发布铺垫 ① init_by_lua* init_by_lua init_by_lua_block 特点: 在openresty start、reload、restart时执行,属于master init 阶段机制&#xff1a; nginx master 主进程加载配置文件时&#xff0c;运行全局Lua VM级别上的参数指定的Lua代码场景&#xff1a; …

一文快速创建前端react项目

目前React是最受欢迎和广泛使用的JavaScript库之一。许多知名的公司和组织都在使用React来构建它们的Web应用程序&#xff0c;包括Facebook&#xff0c;Netflix等。学习好React将会使你能够获得更多的就业机会和职业发展机会。 要快速创建React项目&#xff0c;你可以使用Creat…

记录一次OSSClient使用不当导致的OOM排查过程

首发&#xff1a;公众号《赵侠客》 前言 最近线上有个比较边缘的项目出现OOM了&#xff0c;还好这个项目只是做一些离线的任务处理&#xff0c;出现OOM对线上业务没有什么影响&#xff0c;这里记录一下排查的过程 Dump日志查看 项目配置的主要JVM参数设置如下&#xff1a; …

SAP入门到放弃系列之QM质量检验流程概述

目录 一、流程概述二、操作步骤概述2.1 主数据维护2.2 业务操作 一、流程概述 质量检验流程-Inspection Process Flow,通常由于预先设定的一些规则条件自动触发或者手工触发&#xff0c;例如库存地之间的调拨、生产完工入库检验、采购入库的检验、客户交货前检验等等。另外还有…

GMS地下水数值模拟丨GMS各模块、三维地质模型构建及与MODFLOW耦合、地下水流动数值模拟及报告编制、地下水溶质运移模型、反应性溶质运移等

目录 第一部分 地下水数值模拟理论模块 第二部分 地下水数值模拟数据收集、准备及预处理 第三部分 GMS各模块实践 第四部分 三维地质模型构建及与MODFLOW耦合 第五部分 地下水流动数值模拟及报告编制 第六部分 地下水溶质运移模型 第七部分 反应性溶质运移 更多应用 以…

OpenHarmony ArkTS工程目录结构(Stage模型)

一、应用工程结构 图片来源&#xff1a;OpenHarmony官网 AppScope > app.json5&#xff1a;应用的全局配置信息。 entry&#xff1a;OpenHarmony工程模块&#xff0c;编译构建生成一个HAP包。 src > main > ets&#xff1a;用于存放ArkTS源码。 src > main > …

昔日顶流VC宠儿,如今“流血”上市!

今年全球最大IPO安谋控股&#xff08;Arm Holdings&#xff09;成功上市后&#xff0c;美国的IPO市场正在被激活。美国最大的杂货配送平台Instacart近日更新了招股书&#xff0c;将IPO目标价从原来的26-28美元每股上调至28-30美元&#xff0c;对应公司估值约77亿美元-82.8亿美元…

SpringSecurity 核心组件

文章目录 SpringSecurity 结构组件&#xff1a;SecurityContextHolder组件&#xff1a;Authentication组件&#xff1a;UserDetailsService组件&#xff1a;GrantedAuthority组件总结 SpringSecurity 结构 在SpringSecurity中的jar分为4个&#xff0c;作用分别为 jar作用spri…

idea配置tomcat项目,运行起来却无法访问项目

好长时间都没碰使用tomcat部署的老项目了 最近碰到一个tomcat老项目&#xff0c;都忘记怎么用idea配置了 按记忆配置好之后&#xff0c;启动tomcat&#xff0c;却怎么也访问不了项目 最后才发现根本没有启动编译后的项目代码 只需要右键项目&#xff0c;选择Open Module Se…

如何通过百度SEO优化提升网站排名(掌握基础概念,实现有效优化)

随着互联网的发展&#xff0c;搜索引擎优化&#xff08;SEO&#xff09;成为了网站优化中不可或缺的一部分。在中国&#xff0c;百度搜索引擎占据着主导地位&#xff0c;因此掌握百度SEO概念和优化技巧对网站的排名和曝光非常重要。 百度SEO排名的6个有效方法&#xff1a; 首…

福建企业可以申请泛域名https证书吗

https域名https证书中有一种比较特殊的https证书&#xff0c;可以用一张https证书保护主域名以及主域名下所有子域名&#xff0c;这种证书通常被称为通配符https证书或泛域名https证书。那么企业可以申请泛域名https证书吗?今天就随SSL盾小编了解泛域名https证书。 1.泛域名h…

共享门店模式:让你的连锁门店变成金鸡母

共享门店模式是一种创新的经营方式&#xff0c;它可以让门店的资源和收益与其他人共享&#xff0c;实现互利共赢。共享门店模式有两种主要形式&#xff1a;投资型和消费型。投资型共享门店模式需要股东投入一定的资金&#xff0c;用于锁客和获取分红收益。消费型共享门店模式则…

【免费内网穿透】cpolar从0开始使用

cpolar从0开始使用 具体步骤cpolar下载注册安装 安装启动创建或修改启动 公网远程访问内网web站点初步完成 最近学习到的新东西。 原理类似于使用cpolar的服务器进行跳转 具体步骤 下载CPOLAR 在您的机器上下载并运行cpolar客户端&#xff0c;并为其提供一个本地的网络服务的…

如何合并pdf?三种合并方法教会你

如何合并pdf&#xff1f;合并PDF文件可以将多个PDF文档合并为一个文件&#xff0c;提高文件管理的效率和便利性。无论是为了整理和归档文件&#xff0c;还是为了方便共享和传输文件&#xff0c;合并PDF都是非常实用的操作。通过合并PDF&#xff0c;可以将相关的文件整合在一起&…

项目管理:管理成果是控制还是天意?项目经理的责任是什么?

有人坚信管理具有决定性的作用&#xff0c;主张管理者需对组织的成功或失败负全责。 另一些人则认为&#xff0c;管理者对管理成果的影响其实相当有限&#xff0c;因为存在许多他们无法控制的因素。 组织的成功或失败往往更多地归因于这些无法控制的因素&#xff0c;而非管理者…

浏览器代理解决方案

当谈到网络浏览器&#xff0c; 浏览器 无疑是最受欢迎和广泛使用的选项之一。然而&#xff0c;你可能已经注意到&#xff0c; 浏览器并不原生支持 SOCKS5 代理协议。不过&#xff0c;别担心&#xff01;在本文中&#xff0c;我将与你分享一些解决方案&#xff0c;让你能够在 浏…

黑马JVM总结(十三)

&#xff08;1&#xff09;软引用_引用队列 上面我们们使用软引用我们发现在内存不足时&#xff0c;会把软引用对应的Byte数组对象&#xff0c;进行一个释放&#xff0c;但是我们发现遍历lIst集合的时候一些软引用的对象已经是null了&#xff0c;这些没必要在把它们保存到List…

哨兵模式(sentinel)

为什么需要哨兵模式 redis的主从复制模式能够缓解“读压力”&#xff0c;但是存在两个明显问题。 主节点发生故障&#xff0c;进行主节点切换的过程比较复杂&#xff0c;需要人工参与&#xff0c;导致故障恢复时间无法保障主节点通过主从复制模式将读压力分散出去&#xff0c…

【算法】算法设计与分析 课程笔记 第一章 概述

第一章 算法概述 算法的性质 算法的四个性质&#xff1a;输入、输出、确定性和有穷性。 算法的时间复杂度 1. 常见的时间复杂度 常数阶 O(1) 对数阶 O(log n) 线性阶 O(n) 线性对数阶 O(nlog n) 平方阶 O(n^2) 立方阶 O(n^3) k 次方阶 O(n^k) 指数阶 O(2^n) 注&…

Prompt 策略:代码库 AI 助手的语义化搜索设计

在过去的一周里&#xff0c;为了更好的构建 AI Agent 框架 Chocolate Factory&#xff08;以下简称 CF&#xff09;&#xff0c;我们加入了一个新的应用&#xff1a;代码库 AI 助手。 在设计时&#xff0c;为了更好的在框架底层提供这种能力&#xff0c;我们参阅了 Bloop 应用、…