-
-
http://www.hawstein.com/posts/make-thiner-programming-pearls.html 取样问题 问题:对于整数m和n,其中m<n,输出0~n-1范围内m个随机整数的 有序列表 , 不允许重复。 比如m=3, n=5,...
-
aabb 完全平方數 - KAIKAIKAI - SegmentFault 輸出所有aabb的四位完全平方數(即前兩位數字相等,後兩位數字也相等) 第一次看到這個問題是這麼想的 for ( int i = 1000 ; i < 10000 ; i++ ...
-
Top k elements with most occurrences – Cracking Code Find k elements within a array with most occurrences. public static void ma...
-
http://www.geeksforgeeks.org/the-lazy-caterers-problem/ http://www.geeksforgeeks.org/pizza-cut-problem-circle-division-lines/ Given an in...
-
http://bookshadow.com/weblog/2016/08/28/leetcode-perfect-rectangle/ Given N axis-aligned rectangles where N > 0, determine if they all...
-
http://bookshadow.com/weblog/2016/08/28/leetcode-elimination-game/ There is a list of sorted integers from 1 to n . Starting from left t...
-
Number of Triangles in an Undirected Graph - GeeksforGeeks Given an Undirected simple graph, We need to find how many triangles it can hav...
-
Subtract Two Numbers represented as Linked Lists - GeeksforGeeks Given two linked lists that represent two large positive numbers. Subtrac...
-
http://www.1point3acres.com/bbs/thread-147482-1-1.html 找一个sorted array里面出现次数多于N/4的元素 就是0 ,n/4, 2n/4, 3n/4, n。 然后分别左右搜索 public st...