摘要: Family Gathering at Christmas 题目描述 Every year, Alice’s family has a gathering at Christmas, at a family member’s place. The members would like to choo 阅读全文
posted @ 2018-09-04 10:23 lglh 阅读(431) 评论(0) 推荐(0) 编辑
摘要: Flashing Fluorescents 题目描述 You have n lights, each with its own button, in a line. Pressing a light’s button will toggle that light’s state; if the li 阅读全文
posted @ 2018-08-29 22:36 lglh 阅读(239) 评论(0) 推荐(0) 编辑
摘要: Breaking Biscuits 题目描述 This year, Walter’s workplace resolved to try something radically different: they’re going to change the weekly order of biscui 阅读全文
posted @ 2018-08-28 18:48 lglh 阅读(281) 评论(0) 推荐(0) 编辑
摘要: 棋盘V 题目描述 有一块棋盘,棋盘的边长为100000,行和列的编号为1到100000。棋盘上有n个特殊格子,任意两个格子的位置都不相同。现在小K要猜哪些格子是特殊格子。她知道所有格子的横坐标和纵坐标,但并不知道对应关系。换言之,她只有两个数组,一个存下了所有格子的横坐标,另一个存下了所有格子的纵坐 阅读全文
posted @ 2018-08-28 10:48 lglh 阅读(252) 评论(0) 推荐(0) 编辑
摘要: Count Numbers 题目描述 Now Alice wants to sum up all integers whose digit sum is exactly ab .However we all know the number of this kind of integers are u 阅读全文
posted @ 2018-08-25 21:29 lglh 阅读(333) 评论(0) 推荐(0) 编辑
摘要: Videos 题目描述 C-bacteria takes charge of two kinds of videos: ’The Collection of Silly Games’ and ’The Collection of Horrible Games’.For simplicity’s sa 阅读全文
posted @ 2018-08-23 17:01 lglh 阅读(1196) 评论(0) 推荐(0) 编辑
摘要: C: Shuffle Cards 题目描述 Eddy likes to play cards game since there are always lots of randomness in the game. For most of the cards game, the very first 阅读全文
posted @ 2018-08-21 10:38 lglh 阅读(372) 评论(0) 推荐(0) 编辑
摘要: 问题 K: 求和VII 题目描述 master对树上的求和非常感兴趣。他生成了一棵有根树,并且希望多次询问这棵树上一段路径上所有节点深度的k次方和,而且每次的k可能是不同的。此处节点深度的定义是这个节点到根的路径上的边数。他把这个问题交给了pupil,但pupil并不会这么复杂的操作,你能帮他解决吗 阅读全文
posted @ 2018-08-10 20:35 lglh 阅读(204) 评论(0) 推荐(0) 编辑
摘要: 6617: Finite Encyclopedia of Integer Sequences 题目描述 In Finite Encyclopedia of Integer Sequences (FEIS), all integer sequences of lengths between 1 and 阅读全文
posted @ 2018-08-09 10:49 lglh 阅读(118) 评论(0) 推荐(0) 编辑
摘要: 6759: 异或序列 题目描述 已知一个长度为n的整数数列a1,a2,…,an,给定查询参数l、r,问在al,al+1,…,ar区间内,有多少子序列满足异或和等于k。也就是说,对于所有的x,y(l≤x≤y≤r),满足ax⊕ax+1⊕⋯⊕ay=k的x,y有多少组。 输入 输入第一行为3个整数n,m,k 阅读全文
posted @ 2018-08-08 18:39 lglh 阅读(549) 评论(0) 推荐(0) 编辑