摘要: Given two strings s and t, determine if they are isomorphic. Two strings are isomorphic if the characters in s can be replaced to get t. All occurrenc 阅读全文
posted @ 2017-10-07 16:55 immjc 阅读(175) 评论(0) 推荐(0) 编辑
摘要: Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum. F 阅读全文
posted @ 2017-10-07 16:07 immjc 阅读(118) 评论(0) 推荐(0) 编辑
摘要: The count-and-say sequence is the sequence of integers with the first five terms as following: 1 is read off as "one 1" or 11.11 is read off as "two 1 阅读全文
posted @ 2017-10-07 12:07 immjc 阅读(130) 评论(0) 推荐(0) 编辑
摘要: Given a linked list, determine if it has a cycle in it. Follow up:Can you solve it without using extra space? 带环链表的检测,使用快慢指针判断,快指针每次走两步,慢指针每次走一步,如果快慢指 阅读全文
posted @ 2017-10-07 11:42 immjc 阅读(149) 评论(0) 推荐(0) 编辑