上一页 1 2 3 4 5 6 ··· 64 下一页
摘要: 最大平均数 题目描述 给定长度为 $n$ 的整数数组 $a=(a_1,\dots,a_n)$,且每个数均为 $6$ 的倍数。对于 $1 \le i < j \le n$,定义 $f(i,j) = \max_{\, i \leq l < r \leq j} \frac{a_l + a_{l+1} + 阅读全文
posted @ 2025-12-16 23:59 onlyblues 阅读(16) 评论(0) 推荐(0)
摘要: D. Fibonacci Paths You are given a directed graph consisting of $n$ vertices and $m$ edges. Each vertex $v$ corresponds to a positive number $a_v$. Co 阅读全文
posted @ 2025-12-15 20:32 onlyblues 阅读(42) 评论(0) 推荐(0)
摘要: 公约数距 定义一个整数序列 $B=(B_1,B_2,\dots,B_k)$ 的分数为 $\sum_{i=1}^{k} \sum_{j=1}^{i-1} \gcd (B_i,B_j) \times 2^{(i-j-1)}$。 给出一个整数序列 $A=(A_1,A_2,\dots,A_N)$,求出以下问 阅读全文
posted @ 2025-12-11 20:52 onlyblues 阅读(8) 评论(0) 推荐(0)
摘要: GCDEX - GCD Extreme 题目描述 得定 $n$ ,求 $$\sum\limits_{i=1}^n\sum\limits_{j=i+1}^n\gcd(i,j)$$ 其中 $\gcd(i,j)$ 指的是 $i$ 和 $j$ 的最大公约数。 输入格式 本题有多组数据。 对于每组数据,输出一 阅读全文
posted @ 2025-12-10 16:37 onlyblues 阅读(21) 评论(0) 推荐(0)
摘要: 最大化仿射变换 题目描述 有一个变量 $x$,初始时 $x = 0$。 给定 $n$ 个操作,第 $i$ 个操作定义了一个仿射变换,形式为: $x := a_i x + b_i$ 其中 $:=$ 为赋值号,$a_i$ 和 $b_i$ 均为非负整数。 你需要将这 $n$ 个操作安排一个执行顺序,并依次 阅读全文
posted @ 2025-12-03 14:49 onlyblues 阅读(60) 评论(0) 推荐(0)
摘要: Minimum Operations to Equalize Subarrays You are given an integer array nums and an integer k. In one operation, you can increase or decrease any elem 阅读全文
posted @ 2025-12-01 20:57 onlyblues 阅读(33) 评论(0) 推荐(0)
摘要: 立方数 题目描述 对于给定的正整数 $N$,求最大的正整数 $A$,使得存在正整数 $B$,满足 $A^3B=N$。 输入包含 $T$ 组数据,$1 \leq T \leq 10000$;$1 \leq N \leq 10^{18}$。 输入描述: 第一行数字 $T$ 表示数据组数。 接下来一行,$ 阅读全文
posted @ 2025-11-21 23:24 onlyblues 阅读(10) 评论(0) 推荐(0)
摘要: 这是一场豪赌 题目描述 小徐(上帝角色)准备了 $n$ 个盒子,其中恰有一个盒子里放着礼物,其余盒子都是空的。 小张和小樊轮流进行“猜盒子”游戏,小张先手,整个过程分为两部分,如下。 「选择阶段」:当前玩家从剩余的盒子中任选一个盒子: 若选中有礼物的盒子,则当前玩家获得礼物,游戏结束。 若选中空盒, 阅读全文
posted @ 2025-11-03 11:16 onlyblues 阅读(31) 评论(0) 推荐(0)
摘要: E - Hit and Away Problem Statement You are given a simple connected undirected graph $G$ with $N$ vertices and $M$ edges.The vertices and edges of $G$ 阅读全文
posted @ 2025-10-29 10:35 onlyblues 阅读(21) 评论(0) 推荐(0)
摘要: 求函数 题目描述 牛可乐有 $n$ 个一次函数,第 $i$ 个函数为 $f_i(x) = k_i \times x + b_i$。 牛可乐有 $m$ 次操作,每次操作为以下二者其一: $1$ $i$ $k$ $b$ 将 $f_i(x)$ 修改为 $f_i(x) = k \times x + b$。 阅读全文
posted @ 2025-10-23 21:29 onlyblues 阅读(18) 评论(0) 推荐(1)
上一页 1 2 3 4 5 6 ··· 64 下一页
Web Analytics