小小程序媛  
得之坦然,失之淡然,顺其自然,争其必然
上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 34 下一页

2015年10月14日

摘要: 题目Given a binary tree, determine if it is height-balanced.For this problem, a height-balanced binary tree is defined as a binary tree in whic... 阅读全文
posted @ 2015-10-14 15:02 Coding菌 阅读(125) 评论(0) 推荐(0) 编辑
 
摘要: 题目Given a binary tree, return the bottom-up level order traversal of its nodes’ values. (ie, from left to right, level by level from leaf to ... 阅读全文
posted @ 2015-10-14 14:17 Coding菌 阅读(109) 评论(0) 推荐(0) 编辑

2015年10月13日

摘要: 题目Given a binary tree, return the zigzag level order traversal of its nodes’ values. (ie, from left to right, then right to left for the next... 阅读全文
posted @ 2015-10-13 14:47 Coding菌 阅读(117) 评论(0) 推荐(0) 编辑
 
摘要: 题目Given a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path from the root node down to the ... 阅读全文
posted @ 2015-10-13 14:27 Coding菌 阅读(96) 评论(0) 推荐(0) 编辑

2015年10月12日

摘要: 题目Given a binary tree, return the level order traversal of its nodes’ values. (ie, from left to right, level by level).For example: Given bin... 阅读全文
posted @ 2015-10-12 16:45 Coding菌 阅读(99) 评论(0) 推荐(0) 编辑
 
摘要: 题目Given a binary tree, determine if it is a valid binary search tree (BST).Assume a BST is defined as follows:The left subtree of a node cont... 阅读全文
posted @ 2015-10-12 16:00 Coding菌 阅读(112) 评论(0) 推荐(0) 编辑

2015年10月11日

摘要: 题目Given n, how many structurally unique BST’s (binary search trees) that store values 1…n?For example, Given n = 3, there are a total of 5 un... 阅读全文
posted @ 2015-10-11 15:51 Coding菌 阅读(95) 评论(0) 推荐(0) 编辑
 
摘要: 题目Given n, generate all structurally unique BST’s (binary search trees) that store values 1…n.For example, Given n = 3, your program should r... 阅读全文
posted @ 2015-10-11 15:09 Coding菌 阅读(110) 评论(0) 推荐(0) 编辑

2015年10月10日

摘要: 题目A message containing letters from A-Z is being encoded to numbers using the following mapping:‘A’ -> 1 ‘B’ -> 2 … ‘Z’ -> 26 Given an encode... 阅读全文
posted @ 2015-10-10 16:05 Coding菌 阅读(715) 评论(0) 推荐(0) 编辑

2015年10月9日

摘要: 题目Given an index k, return the kth row of the Pascal’s triangle.For example, given k = 3, Return [1,3,3,1].Note: Could you optimize your algo... 阅读全文
posted @ 2015-10-09 21:33 Coding菌 阅读(103) 评论(0) 推荐(0) 编辑
上一页 1 ··· 8 9 10 11 12 13 14 15 16 ··· 34 下一页