摘要:
Mergeksorted linked lists and return it as one sorted list. Analyze and describe its complexity.想法很简单,就是两两合并。在Merge Two Sorted Lists这道题已经实现了两两合并的代码了,就... 阅读全文
摘要:
Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent a number.An example is the root-to-leaf path 1->2->3 which... 阅读全文
摘要:
Given a 2D board containing 'X' and 'O', capture all regions surrounded by 'X'.A region is captured by flipping all 'O's into 'X's in that surrounded ... 阅读全文
摘要:
Log scale 1 %# some random data 2 x = 2.^(0:10); 3 y = rand(size(x)); 4 5 plot(log2(x), y) %# plot on log2 x-scale 6 se... 阅读全文
摘要:
Valid PalindromeGiven a string, determine if it is a palindrome, considering only alphanumeric characters and ignoring cases.For example,"A man, a pla... 阅读全文