educational codeforces round 119

NSSCTF Round#16 Basic WriteUp

NSSCTF Round#16Basic wp 目录NSSCTF Round#16Basic wp一.pwn1.nc_pwnre2.ret_text 一.pwn 1.nc_pwnre nc连接 得到题目,给了一段汇编代码以及40个十六进制数字 分析代码可知,将一个字符串与10h即16进行异或运算,二 ......
WriteUp NSSCTF Basic Round 16

Hey left 1 Codeforces Round 918 (Div. 4)

题目链接 A. 3个数,其中2个数相同,输出不相同的那个 可以用if else判断,较为麻烦 用的map,输出出现一次的 #include <bits/stdc++.h> using namespace std; const int N=1e5+10; void solve(){ map<int,i ......
Codeforces Round left Hey 918

CodeForces 1312G Autocompletion

洛谷传送门 CF 传送门 考虑直接在题目给的 Trie 上 dp,设 \(f_u\) 为打出 \(u\) 结点的串的最小代价。 首先我们有 \(f_u \gets f_{fa_u} + 1\)。 我们有 \(f_u \gets \min\limits_v f_v + t + 1\),要求 \(u\) ......
Autocompletion CodeForces 1312G 1312

Educational Codeforces Round 152 (Rated for Div. 2)

layout: ../../layouts/MarkdownPostLayout.astro title: 'Educational Codeforces Round 152 (Rated for Div. 2)' pubDate: 2024-01-11 description: '一些训练' au ......
Educational Codeforces Round Rated 152

codeforces 918 div4

C 题意 : 给定一些数,问这些数的和是不是完全平方数(5*5这样) #include<cmath> #include<iostream> #define ll long long using namespace std; bool issq(ll n){ ll root = sqrt(n); re ......
codeforces div4 918 div

Unlocking the Road to Success: The Benefits of Online Driver's Education

In the fast-paced world we live in, online education has become a staple for acquiring new skills and knowledge. This trend extends to driver's educat ......
Unlocking Education Benefits Success Online

CF Beta Round 93-D.Fibonacci Sums-齐肯多夫分解、DP

CF Beta Round 93-D.Fibonacci Sums-齐肯多夫分解、DP https://codeforces.com/contest/126/problem/D 定义Fibonacci序列:\(F_1=1,F_2=2,F_k=F_{k-1}+F_{k-2}(\forall k\geq ......
Fibonacci Round Beta Sums CF

CodeForces 1329D Dreamoon Likes Strings

洛谷传送门 CF 传送门 考虑构造一个新串 \(t\),只保留原串 \(s_{i - 1} = s_i\) 的字符 \(s_i\)。设 \(a_i\) 为 \(t_i\) 在原串的位置。 那么新串上我们有两种操作: \(\forall i\),删除 \(t_i\)(相当于删除原串中的 \([a_i, ......
CodeForces Dreamoon Strings 1329D Likes

CodeForces 1237H Balanced Reversals

洛谷传送门 CF 传送门 容易想到把 \(s, t\) 分成长度为 \(2\) 的段考虑。容易发现 \(00, 11\) 的个数在操作过程中不会改变,所以若两串的 \(00\) 或 \(11\) 个数不相等则无解。 考虑依次对 \(i = 2, 4, \ldots, n\) 构造 \(s[1 : i ......
CodeForces Reversals Balanced 1237H 1237

vp Codeforces Round 915 (Div. 2)

vp还是比正式打舒服一些。。AB很顺畅,A题。。我只能说玩MC的都一眼秒了好吧 C题,我卡住了,结论非常好推,我直接退出来了,但是,问题是我对特例的判断不是很熟悉,或者说不是很敏感。这是一个大问题,我在wa on test 2的时候,第一反应是去看看这个算法整个有没有什么问题,事实上是没有的那么问题 ......
Codeforces Round 915 Div vp

Codeforces [Hello 2024]

Codeforces Hello 2024 主打一个昏了头 A. Wallet Exchange #include <bits/stdc++.h> #define endl '\n' //#define int long long using namespace std; const int N = ......
Codeforces Hello 2024

CodeForces 1379E Inverse Genealogy

洛谷传送门 CF 传送门 \(n\) 为偶数显然无解。 否则我们可以构造一棵 \(n\) 个点的完全二叉树,当 \(n + 1\) 是 \(2\) 的幂时满足 \(m = 1\),否则 \(m = 0\)。 当 \(n \ge 5\) 时可以递归至 \((n - 2, m - 1)\),再挂一个叶子 ......
CodeForces Genealogy Inverse 1379E 1379

CodeForces 1919F2 Wine Factory (Hard Version)

洛谷传送门 CF 传送门 题目看着感觉很像最大流,不妨建模,\(S \to i\),容量为 \(a_i\);\(i \to T\),容量为 \(b_i\);\(i \to i + 1\),容量为 \(c_i\)。答案是这个图的最大流。 考虑最大流转最小割。观察到 \(S \to i\) 和 \(i ......
CodeForces Factory Version 1919F2 1919F

CodeForces 1919E Counting Prefixes

洛谷传送门 CF 传送门 考虑一个很类似的题。我们把正数和负数分开来考虑,最后用 \(0\) 连接一些连续段,形如 \(0 - \text{正} - 0 - \text{正} - 0 - \text{负}\)。 先考虑正数。设 \(f_{i, j}\) 为考虑了 \(\ge i\) 的正数,形成了 ......
CodeForces Counting Prefixes 1919E 1919

【题解】Codeforces 1876G Clubstep

首先考虑暴力的贪心。 从 \(r\) 到 \(l\) 依次遍历,若 \(a_i < x\) 则一直进行题目中的操作。 正确性是能保证的,因为选后面的 \(j\) 只能 \(+ 1\),而选 \(i\) 可以 \(+2\),且 \(i\) 前面的部分都是 \(+1\)。 考虑转化一下,把对 \(i\) ......
题解 Codeforces Clubstep 1876G 1876

【题解】Codeforces 1852D Miriany and Matchstick

首先考虑到第一行是固定的,先去掉第一行的贡献。 接下来会有一个 \(O(n^2)\) 的 \(\text{DP}\)。 考虑设 \(f_{i, 0 / 1, j}\) 为考虑了 \(1\sim i\) 列的放置,第 \(i\) 列填 \(\text{A / B}\) 且对数为 \(j\) 是否可行。 ......
题解 Codeforces Matchstick Miriany 1852D

vp Educational Codeforces Round 160 (Rated for Div. 2)

ABC很顺畅,没有卡住然后到最后D都做不出来 D我感觉是一个类似计数dp的东西但是我找不到统计的规律但是可以得到一些性质:一个数字如果想被删掉,那它直到它左边的比它小的数字为止所有数字都要先删掉,它才能被删掉 发现自己如果不去想DP,会去往贪心的方向想,这题就是那种贪心没法完全被判断掉的因为贪心也有 ......
Educational Codeforces Round Rated 160

codeforces比赛(4):codeforces hello_2024

A、Wallet Exchange 跳转原题点击此:A题地址 1、题目大意 经典贪心:A和B玩游戏,两人依次进行以下两个操作(注意这两个操作是依次进行,而不是选择操作!!!)是:1、交换钱包或保留钱包;2、从玩家当前钱包中取出1枚硬币(注意不能为0)。 A先走,并且当某位玩家无法做出有效举动时,另一 ......
codeforces hello 2024

CodeForces Hello 2024 个人题解(A~C)

A. Wallet Exchange 时间限制: 1秒 内存限制: 256兆 输入: 标准输入 输出: 标准输出 Alice and Bob are bored, so they decide to play a game with their wallets. Alice has a coins ......
题解 CodeForces Hello 个人 2024

[Codeforces] CF1553D Backspace

CF1553D Backspace 说实话这题不配绿题 题目传送门 题面 给你两个字符串 \(S,T\) ,问你能否通过将 \(S\) 中的若干个数换成 Backspace 来使其变成 \(T\) 。Backspace 能删去前一个输入的字符。 思路 很明显,如果将一个字符换成Backspace,那 ......
Codeforces Backspace 1553D 1553 CF

[Codeforces] CF1551C Interesting Story

CF1551C Interesting Story 题目传送门 题意 给定 \(n\) 个仅由 \(\texttt{a,b,c,d,e}\) 组成的单词 (\(n \le 2\times 10^5\)),从其中选出尽可能多的单词,使得存在某个字母在这些单词中出现的次数比其他所有字母的出现次数之和还要 ......
Interesting Codeforces 1551C Story 1551

P9989 [Ynoi Easy Round 2023] TEST_69

[Ynoi Easy Round 2023] TEST_69 Luogu P9989 题目描述 给定一个长为 \(n\) 的序列 \(a\),有 \(m\) 次操作。 每次有两种操作: 1 l r x:对于区间 \([l,r]\) 内所有 \(i\),将 \(a_i\) 变成 \(\gcd(a_i, ......
P9989 Round 9989 2023 Easy

P8512 [Ynoi Easy Round 2021] TEST_152 题解

P8512 直接做不好做,考虑离线。这个覆盖操作和这道题很像,可以直接对某些段暴力修改,可以直接上 ODT。发现当 ODT 执行这些操作时,是容易求出不执行某些操作后带来的值的影响的,即可以直接用树状数组维护每个位置现在是被那个操作覆盖,求出 \(1\) 到 \(x\) 操作还覆盖了那些位置,以及这 ......
题解 P8512 Round 8512 2021

Codeforces Round 917 (Div. 2)

Codeforces Round 917 (Div. 2) 康复训练 A. Least Product #include <bits/stdc++.h> #define endl '\n' using namespace std; int n; void solve(){ cin >> n; int ......
Codeforces Round 917 Div

Codeforces Round 918 (Div. 4)

D. Unnatural Language Processing 给字符串元素按要求间隔”.“ #include<bits/stdc++.h> using namespace std; void solve(){ int n; string s; cin>>n>>s; string o=s; for ......
Codeforces Round 918 Div

Codeforces Round 917 (Div. 2)

A. Least Product 求乘积最小,可以改数组元素 #include<bits/stdc++.h> #define int long long using namespace std; void solve(){ int n; cin>>n; int ans=1; for(int i=1; ......
Codeforces Round 917 Div

2024 AIGC 应用层十大趋势;iPhone 遭史上最复杂攻击!丨 RTE 开发者日报 Vol.119

开发者朋友们大家好: 这里是 「RTE 开发者日报」 ,每天和大家一起看新闻、聊八卦。我们的社区编辑团队会整理分享 RTE (Real Time Engagement) 领域内「有话题的 新闻 」、「有态度的 观点 」、「有意思的 数据 」、「有思考的 文章 」、「有看点的 会议 」,但内容仅代表编 ......
应用层 开发者 趋势 日报 iPhone

Codeforces 1852D Miriany and Matchstick

首先考虑到第一行是固定的,先去掉第一行的贡献。 接下来会有一个 \(O(n^2)\) 的 \(\text{DP}\)。 考虑设 \(f_{i, 0 / 1, j}\) 为考虑了 \(1\sim i\) 列的放置,第 \(i\) 列填 \(\text{A / B}\) 且对数为 \(j\) 是否可行。 ......
Codeforces Matchstick Miriany 1852D 1852

Educational Codeforces Round 160 (Rated for Div. 2)

A 直接模拟,注意细节 #include<bits/stdc++.h> #define ll long long using namespace std; ll p[15] = {1}; void solve() { ll x; cin >> x; int len = 0; while(x / p[ ......
Educational Codeforces Round Rated 160

HydroOJ 从入门到入土(12)解决 codeforces 可以爬取但提交 Forbidden(>4.10.1)

故障内容 在使用Hydro(>4.10.1)的插件 vjudge 远程评测 codeforces 的题目的时候,会遇到题目可以正常爬,但是提交却显示Forbidden的问题。 故障分析 首先看网络。但题目可以正常爬,所以首先排除网络问题。 搜索了一下相关问题,找到一条相关信息,说 UA 可能影响在c ......
codeforces Forbidden HydroOJ 10 gt
共2000篇  :1/67页 首页上一页1下一页尾页