随笔分类 -  数据结构

摘要:给出长度相同的两个字符串:A 和 B,其中 A[i] 和 B[i] 是一组等价字符。举个例子,如果 A = "abc" 且 B = "cde",那么就有 'a' == 'c', 'b' == 'd', 'c' == 'e'。 等价字符遵循任何等价关系的一般规则: 自反性:'a' == 'a' 对称性 阅读全文
posted @ 2019-04-21 20:08 樱花落舞 阅读(304) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2017-07-27 00:18 樱花落舞 阅读(218) 评论(0) 推荐(0) 编辑
摘要:Mahmoud and Ehab live in a country with n cities numbered from 1 to n and connected by n - 1 undirected roads. It's guaranteed that you can reach any 阅读全文
posted @ 2017-07-26 01:43 樱花落舞 阅读(237) 评论(0) 推荐(0) 编辑
摘要:Mahmoud wants to write a new dictionary that contains n words and relations between them. There are two types of relations: synonymy (i. e. the two wo 阅读全文
posted @ 2017-07-26 01:32 樱花落舞 阅读(270) 评论(0) 推荐(0) 编辑
摘要:Moriarty has trapped n people in n distinct rooms in a hotel. Some rooms are locked, others are unlocked. But, there is a condition that the people in 阅读全文
posted @ 2017-07-23 00:49 樱花落舞 阅读(265) 评论(0) 推荐(0) 编辑
摘要: 阅读全文
posted @ 2017-07-14 19:30 樱花落舞 阅读(156) 评论(0) 推荐(0) 编辑
摘要:有一天,空和白很无聊,决定玩盛大游戏,考虑到两个人玩,他们随便掏了一个游戏出来:在一个n∗m 的棋盘上,首先把史蒂芬妮·多拉放在左上角(1,1) 的位置。每次一个人可以将她往下,往右,往右下丢一格。当前回合,谁不能丢史蒂芬妮,谁就输了。(注意,不可以把活人丢出棋盘啦!)游戏总是空先手。 白说,这是一 阅读全文
posted @ 2017-07-13 23:42 樱花落舞 阅读(228) 评论(0) 推荐(0) 编辑
摘要:Vova again tries to play some computer card game. The rules of deck creation in this game are simple. Vova is given an existing deck of n cards and a 阅读全文
posted @ 2017-07-07 23:46 樱花落舞 阅读(628) 评论(0) 推荐(1) 编辑
摘要: 阅读全文
posted @ 2017-07-07 10:53 樱花落舞 阅读(227) 评论(0) 推荐(0) 编辑
摘要:Description Parmida is a clever girl and she wants to participate in Olympiads this year. Of course she wants her partner to be clever too (although h 阅读全文
posted @ 2017-03-19 20:24 樱花落舞 阅读(211) 评论(0) 推荐(0) 编辑
摘要:《数据结构》严蔚敏 头文件SQlist.h 函数实现 阅读全文
posted @ 2016-04-27 20:42 樱花落舞 阅读(321) 评论(0) 推荐(0) 编辑
摘要:《数据结构》严蔚敏 头文件Stacksq.h 函数实现 阅读全文
posted @ 2016-04-27 09:44 樱花落舞 阅读(407) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示