随笔分类 -  BFS

摘要:Given two words (beginWordandendWord), and a dictionary's word list, find all shortest transformation sequence(s) frombeginWordtoendWord, such that:On... 阅读全文
posted @ 2016-01-17 05:44 Hygeia 阅读(345) 评论(0) 推荐(0)
摘要:Given two words (beginWordandendWord), and a dictionary's word list, find the length of shortest transformation sequence frombeginWordtoendWord, such ... 阅读全文
posted @ 2016-01-15 13:58 Hygeia 阅读(257) 评论(0) 推荐(0)
摘要:Serialization is the process of converting a data structure or object into a sequence of bits so that it can be stored in a file or memory buffer, or ... 阅读全文
posted @ 2016-01-01 11:34 Hygeia 阅读(189) 评论(0) 推荐(0)
摘要:Given a binary tree, return thezigzag level ordertraversal of its nodes' values. (ie, from left to right, then right to left for the next level and al... 阅读全文
posted @ 2015-12-31 05:47 Hygeia 阅读(143) 评论(0) 推荐(0)
摘要:题目:Given a binary tree, return thebottom-up level ordertraversal of its nodes' values. (ie, from left to right, level by level from leaf to root).For ... 阅读全文
posted @ 2015-08-05 10:39 Hygeia 阅读(170) 评论(0) 推荐(0)
摘要:题目:Given a binary tree, return thelevel ordertraversal of its nodes' values. (ie, from left to right, level by level).For example:Given binary tree{3,... 阅读全文
posted @ 2015-08-05 10:33 Hygeia 阅读(403) 评论(0) 推荐(0)