回馈本版,贴GOOGLE电话面经# JobHunting - 待字闺中
I*A
1 楼
45分钟,问了三道题目
(1)Give some scenarios where you might favor O(n^2) algorithm over a O(nlg
(n)) one
(2)Implement an algorithm int removeDuplicate(char[] s)
For instance change ”abbcccdda” to “abcda” and return 4(the number of
characters deleted).
(3)Implement an algorithm to check whether brace expressions are valid or
not
boolean isGood(String s, String braces); //assume braces are valid,{}[]()
题目超级简单
可是CODE第三题的时候犯了两个小的超级低级的错误
interviewer一问,我立刻就明白了忘了check。。。
郁闷死
(1)Give some scenarios where you might favor O(n^2) algorithm over a O(nlg
(n)) one
(2)Implement an algorithm int removeDuplicate(char[] s)
For instance change ”abbcccdda” to “abcda” and return 4(the number of
characters deleted).
(3)Implement an algorithm to check whether brace expressions are valid or
not
boolean isGood(String s, String braces); //assume braces are valid,{}[]()
题目超级简单
可是CODE第三题的时候犯了两个小的超级低级的错误
interviewer一问,我立刻就明白了忘了check。。。
郁闷死