
Recent Posts
Recent Comments
Mr WordPress on Hello world! Archives
Categories
Meta
Tag Archives: Data Structure
Programming Reflection (Jun 8, 2017)
1. BITT Principle Brute Force （暴力解法，低效/费空间） Improvement （优化解法，高效/省空间） Time and space complexity （时间/空间复杂度） Test （测试） 2. Array is sorted and may have better performance （3Sum o(n^2) solution) 数组排序过后可能有奇效 3. Test cases are designed on purpose to test the functionality, not … Continue reading
Posted in CS Research&Application, Intern&Job, Uncategorized
Tagged Algorithm, Data Structure
Leave a comment
Java Data Structure Summary
Data Structure in Java ArrayList — Resizable Array Implementation 1.5x resize if necessary GC vs ARC runtime vs compile time https://stackoverflow.com/questions/7874342/whatisthedifferencebetweenobjectivecautomaticreferencecountingandgarb Right shift vs Division 1. faster 2. pure integer 3. no intermediate solution overflow issue (safer, avoid stack overflow) … Continue reading
Programming Reflection (Jun 1, 2017)
1. Programming, programming, programming Keep brushing up algorithm and data structure problems Summarize the approach and the process to figure out solution 多刷题 多总结（回顾解题思路） 2. Technical Knowledge: Breadth vs Depth Concentrate on one in early stage, then learn about more 职业早期专精一门，之后拓展广度 … Continue reading
Posted in CS Research&Application, Intern&Job, Uncategorized
Tagged Algorithm, Data Structure
Leave a comment
Programming Reflection May 17
1. Array is easy to index specific element with index, it’s easier to calculate the difference between different elements than linked list. 2. LeetCode Trap Rain Water problem: iterate left and right elements for each element in the input array, … Continue reading
Posted in CS Research&Application, Intern&Job, IT, Uncategorized
Tagged Algorithm, Data Structure, LeetCode, programming
Leave a comment
Leet Code Summary and Reflection
Array Tips: keep two points and shrink from left and right to center, check to meet certain requirement (sum equals a target number) until left index is over right one. Problems: Two Sum, 3Sum, 3Sum Closest, 4Sum, etc. … Continue reading
Posted in CS Research&Application, Intern&Job, IT, Uncategorized
Tagged Algorithm, Data Structure, LeetCode
Leave a comment
Programming Reflections Mar 9
1. Create binary search tree from sorted array or linked list: It cannot access element via index in linked list as array, it uses direction to next node. Array creates root by middle term first, but linked list creates left … Continue reading
Posted in CS Research&Application
Tagged Algorithm, array, Data Structure, linked list, stack, tree
Leave a comment
Algorithm and Data Structure – Counting Anagrams
Recently I played an algorithm and data structure question which is called Counting Anagrams, its requirement is like: Input 2 abdcghbaabcdij bcda bbbababaaabbbb ab Output 2 0 8 6 2 3 4 5 6 9 As first … Continue reading
Posted in CS Research&Application, Uncategorized
Tagged Algorithm, Data Structure, Java
Leave a comment