Loading

上一页 1 ··· 19 20 21 22 23 24 25 26 27 ··· 75 下一页
摘要: 链接:https://ac.nowcoder.com/acm/contest/11255/F 来源:牛客网 题目描述 Alice and Bob are playing a game. At the beginning, there is an undirected graph GG with nn 阅读全文
posted @ 2021-07-26 18:48 脂环 阅读(90) 评论(0) 推荐(0) 编辑
摘要: 链接:https://ac.nowcoder.com/acm/contest/11255/I 来源:牛客网 题目描述 For a sequence t1...nt1...n, we define the weight of it is the number of pairs (i,j)(i,j) s 阅读全文
posted @ 2021-07-26 18:42 脂环 阅读(79) 评论(0) 推荐(1) 编辑
摘要: 链接:https://ac.nowcoder.com/acm/contest/11255/C 来源:牛客网 题目描述 Let LCS(s1,s2)LCS(s1,s2) denote the length of the longest common subsequence (not necessary 阅读全文
posted @ 2021-07-26 18:41 脂环 阅读(92) 评论(0) 推荐(0) 编辑
摘要: 链接:https://ac.nowcoder.com/acm/contest/11255/J 来源:牛客网 题目描述 Bob has an n×mn×m matrix WW. This matrix is very special, It's calculated by two sequences 阅读全文
posted @ 2021-07-26 18:40 脂环 阅读(296) 评论(0) 推荐(0) 编辑
摘要: 链接:https://ac.nowcoder.com/acm/contest/11254/B 来源:牛客网 题目描述 Goodeat has a white chessboard with n rows and m columns. Each grid (i, j) has a weight c(i 阅读全文
posted @ 2021-07-25 16:06 脂环 阅读(117) 评论(0) 推荐(0) 编辑
摘要: 如果边权不大(1e6以下)的话可以不直接sort而是使用桶排序,开边权范围的vector数组不断往对应的vector里push_back边即可 阅读全文
posted @ 2021-07-25 11:14 脂环 阅读(43) 评论(0) 推荐(0) 编辑
摘要: 链接:https://ac.nowcoder.com/acm/contest/11254/E 来源:牛客网 题目描述 Given n, count the number of pairs of positive integers (x, y), such that xy+1∣x2+y2,1≤x≤y≤ 阅读全文
posted @ 2021-07-25 00:23 脂环 阅读(448) 评论(2) 推荐(3) 编辑
摘要: 链接:https://ac.nowcoder.com/acm/contest/11254/J 来源:牛客网 题目描述 Goodeat finds an undirected complete graph with n vertices. Each edge of the graph is paint 阅读全文
posted @ 2021-07-24 19:07 脂环 阅读(157) 评论(0) 推荐(0) 编辑
摘要: Problem Description Give you a cube with a side length of n-1. Find the number of equilateral triangles with three points on the cube point. Each side 阅读全文
posted @ 2021-07-23 10:42 脂环 阅读(312) 评论(0) 推荐(0) 编辑
摘要: 题目描述 给定一棵nn个点的带权树,结点下标从11开始到NN。寻找树中找两个结点,求最长的异或路径。 异或路径指的是指两个结点之间唯一路径上的所有边权的异或。 输入格式 第一行一个整数NN,表示点数。 接下来 n−1n−1 行,给出 u,v,wu,v,w ,分别表示树上的 uu 点和 vv 点有连边 阅读全文
posted @ 2021-07-22 00:40 脂环 阅读(94) 评论(0) 推荐(0) 编辑
上一页 1 ··· 19 20 21 22 23 24 25 26 27 ··· 75 下一页