原创 搜狐面試心得
筆試: 線上筆試,題目不難一面: 1.項目經歷 2.一個數學邏輯題 3.topk 的解法二面: 1.項目經歷,OA平臺沒介紹清楚(比較嚴重的敗筆,會的一定得講清楚) 2.設計一個學生選課系統,寫了一個,
原创 3Sum Closet
【題目】Given an array S of n integers, find three integers in S such that the sum is closest to a given number, target.
原创 迴文數zigzag
解法一: 利用循環數組進行打印,方法比較簡便,時間複雜度爲O(n)但浪費空間 public class Solution { String convert(String s, int nRows) { int i = 0, j =
原创 Regular Expresssion Matching
class Solution { public: bool isMatch(const char *s, const char *p) { int i, j; int m = strlen(s);
原创 Java 使用線程池遞歸壓縮一個文件夾下的所有子文件
1.Gzip單個文件壓縮package date0805.demo1; import java.io.BufferedInputStream; import java.io.BufferedOutputStream; import ja
原创 Reverse Integer
比較簡單public class Solution { public static int reverse(int x) { long flag = 0; while (x != 0) {