Implement pow(x, n).
原题链接:https://oj.leetcode.com/problems/powx-n/
public double pow(double x, int n) {
if(n== 0)
return 1;
if(n == 1)
return x;
if(n % 2 ==0)
return pow(x*x,n/2);
...
分类:
其他好文 时间:
2014-11-19 11:19:53
阅读次数:
135
https://oj.leetcode.com/problems/binary-tree-level-order-traversal/ Given a binary tree, return the level order traversal of its nodes' values. (ie, f...
分类:
其他好文 时间:
2014-11-19 08:33:46
阅读次数:
179
Given two numbers represented as strings, return multiplication of the numbers as a string.
Note: The numbers can be arbitrarily large and are non-negative.
原题链接:https://oj.leetcode.com/problems...
分类:
其他好文 时间:
2014-11-19 01:52:17
阅读次数:
141
Given an array of strings, return all groups of strings that are anagrams.
Note: All inputs will be in lower-case.
原题链接:https://oj.leetcode.com/problems/anagrams/
易位构词游戏的英文词汇是 anagram,这个词来源于有...
分类:
其他好文 时间:
2014-11-19 01:23:03
阅读次数:
136
Implement pow(x, n).
原题链接:https://oj.leetcode.com/problems/powx-n/
public double pow(double x, int n) {
if(n== 0)
return 1;
if(n == 1)
return x;
if(n % 2 ==0)
return pow(x*x,n/2);
...
分类:
其他好文 时间:
2014-11-19 01:19:41
阅读次数:
157
If $A$ is a contraction, show that $$\bex A^*(I-AA^*)^{1/2}=(I-A^*A)^{1/2}A^*. \eex$$ Use this to show that if $A$ is a contraction on $\scrH$, then t...
分类:
其他好文 时间:
2014-11-19 00:10:53
阅读次数:
315
Let $A=A_1\oplus A_2$. Show that
(1). $W(A)$ is the convex hull of $W(A_1)$ and $W(A_2)$; i.e., the smallest convex set containing $W(A_1)\cup...
分类:
其他好文 时间:
2014-11-19 00:04:31
阅读次数:
272
For every matrix $A$, the matrix $$\bex \sex{\ba{cc} I&A\\ 0&I \ea} \eex$$ is invertible and its inverse is $$\bex \sex{\ba{cc} I&-A\\ 0&I \ea}. \eex$...
分类:
其他好文 时间:
2014-11-18 23:49:24
阅读次数:
217
(1). When $A$ is normal, the set $W(A)$ is the convex hull of the eigenvalues of $A$. For nonnormal matrices, $W(A)$ may be bigger than the convex hul...
分类:
其他好文 时间:
2014-11-18 23:41:26
阅读次数:
243
(1). The numerical radius defines a norm on $\scrL(\scrH)$.
分类:
其他好文 时间:
2014-11-18 23:39:33
阅读次数:
193