KSzsh

导航

2023年4月15日 #

Ian and Array Sorting

摘要: 题目链接 题目描述: To thank Ian, Mary gifted an array $a$ of length $n$ to Ian. To make himself look smart, he wants to make the array in non-decreasing order 阅读全文

posted @ 2023-04-15 11:42 KSzh 阅读(47) 评论(0) 推荐(1) 编辑

2023年2月6日 #

Range Add Query

摘要: 题目链接 题目描述: You are given an integer sequence of length $N$, $A=(A_1 ,A_2 ,…,A_N?)$, and a positive integer $K$. For each $i=1,2,…,Q$, determine whethe 阅读全文

posted @ 2023-02-06 19:07 KSzh 阅读(55) 评论(0) 推荐(0) 编辑

2023年2月3日 #

Flexible String

摘要: 题目链接 题目描述: You have a string $a$ and a string $b$. Both of the strings have length $n$. There are at most 10 different characters in the string a. You 阅读全文

posted @ 2023-02-03 20:40 KSzh 阅读(14) 评论(0) 推荐(0) 编辑

2023年2月1日 #

Remove the Bracket

摘要: 题目链接 题目描述: RSJ has a sequence $a$ of $n$ integers $a_1,a_2,…,a_n$ and $a_n$ integer $s$. For each of $a_2,a_3,…,a_{n?1}$, he chose a pair of non-negat 阅读全文

posted @ 2023-02-01 11:00 KSzh 阅读(16) 评论(0) 推荐(0) 编辑

2023年1月31日 #

Number Factorization

摘要: 题目链接 题目描述: Given an integer $n$. Consider all pairs of integer arrays $a$ and $p$ of the same length such that $n=∏a^{pi}_i$$($i.e. $a^{p1}_1?a^{p2}_2 阅读全文

posted @ 2023-01-31 19:14 KSzh 阅读(15) 评论(0) 推荐(0) 编辑

Vlad and a Pair of Numbers

摘要: 题目链接 题目描述: Vlad found two positive numbers $a$ and $b(a,b>0)$. He discovered that $a⊕b=\frac{a+b}{2}$, where $⊕$ means the bitwise exclusive OR , and 阅读全文

posted @ 2023-01-31 09:39 KSzh 阅读(57) 评论(0) 推荐(0) 编辑

2023年1月30日 #

Matryoshkas

摘要: 题目链接 题目描述: Matryoshka is a wooden toy in the form of a painted doll, inside which you can put a similar doll of a smaller size. A set of nesting dolls 阅读全文

posted @ 2023-01-30 10:43 KSzh 阅读(39) 评论(0) 推荐(0) 编辑

2023年1月26日 #

Min Max Sort

摘要: 题目链接 题目描述: You are given a permutation $p$ of length $n$ (a permutation of length $n$ is an array of length $n$ in which each integer from $1$ to $n$ 阅读全文

posted @ 2023-01-26 23:17 KSzh 阅读(104) 评论(0) 推荐(0) 编辑

2023年1月19日 #

Change Usernames(拓扑序列)

摘要: 题目链接 题目描述: You run a web service with $N$ users. The $i$-th user with a current handle $S_i$ wants to change it to $T_i$. Here, $S_1,…,$ and $S_N$ are 阅读全文

posted @ 2023-01-19 21:00 KSzh 阅读(25) 评论(0) 推荐(0) 编辑

2023年1月12日 #

Gardener and the Array

摘要: 题目链接 题目描述: The gardener Kazimir Kazimirovich has an array of $n$ integers $c_1,c_2,…,c_n$. He wants to check if there are two different subsequences $ 阅读全文

posted @ 2023-01-12 10:18 KSzh 阅读(56) 评论(0) 推荐(0) 编辑