上一页 1 ··· 4 5 6 7 8 9 10 11 12 13 下一页
摘要: 题目: Given a string S and a string T, find the minimum window in S which will contain all the characters in T in complexity O(n). For example,S = "ADOB 阅读全文
posted @ 2016-05-16 13:36 ElNinoT 阅读(144) 评论(0) 推荐(0) 编辑
摘要: 首先给出题目: Given two words word1 and word2, find the minimum number of steps required to convert word1 to word2. (each operation is counted as 1 step.) Y 阅读全文
posted @ 2016-05-14 14:14 ElNinoT 阅读(194) 评论(0) 推荐(0) 编辑
摘要: 题目为: Find the contiguous subarray within an array (containing at least one number) which has the largest sum. For example, given the array [−2,1,−3,4, 阅读全文
posted @ 2016-05-09 12:48 ElNinoT 阅读(154) 评论(0) 推荐(0) 编辑
摘要: N皇后是一个十分经典的问题。 这题一个经典的解法就是回溯法。 一开始使用回溯法的话。陷入了两个误区。 第一,每次回溯都从第一个点开始计算,其实完全没必要。 第二,每次回溯都将当前解空间复制一遍。其实也没有必要。 上网搜了一下解法。核心思想为,因为N皇后问题限制每行只能放一个皇后。所以,考虑以行为维度 阅读全文
posted @ 2016-05-08 19:30 ElNinoT 阅读(181) 评论(0) 推荐(0) 编辑
摘要: Given a collection of distinct numbers, return all possible permutations. For example,[1,2,3] have the following permutations:[1,2,3], [1,3,2], [2,1,3 阅读全文
posted @ 2016-05-04 12:00 ElNinoT 阅读(257) 评论(0) 推荐(0) 编辑
摘要: 题目: Given an array of non-negative integers, you are initially positioned at the first index of the array. Each element in the array represents your m 阅读全文
posted @ 2016-05-03 13:18 ElNinoT 阅读(255) 评论(0) 推荐(0) 编辑
摘要: 前两天去苏州面试微软,结果被拒了。现记录其面试内容及风格 首先,从整体上来说,微软及其看中你对算法的理解。除了问问你的项目做得是什么。其他几乎都是关于算法。 不像其他公司会问你语言特性,操作系统等等概念性的问题。 一面的第一个问题是,如何判断一个单向链表中是否存在一个环。 第二个问题是,给你一个Lo 阅读全文
posted @ 2016-04-23 13:15 ElNinoT 阅读(167) 评论(0) 推荐(0) 编辑
摘要: char *转String (env)->NewStringUTF("the content you want to type in"); char *转jbyteArray jbyte *by = (jbyte*)data;int nOutSize=225*9;jbyteArray jarray 阅读全文
posted @ 2016-03-01 13:34 ElNinoT 阅读(992) 评论(0) 推荐(0) 编辑
摘要: 今天遇到一个掉了一笔的swing类。可以完美的解决JFrame下设置背景的问题。任意size。太掉了。特记于此import java.awt.*;import java.awt.image.BufferedImage;import javax.swing.Icon;import javax.swin... 阅读全文
posted @ 2015-09-17 13:44 ElNinoT 阅读(288) 评论(0) 推荐(0) 编辑
摘要: Java中equals和==的区别java中的数据类型,可分为两类: 1.基本数据类型,也称原始数据类型。byte,short,char,int,long,float,double,boolean 他们之间的比较,应用双等号(==),比较的是他们的值。2.复合数据类型(类) 当他们用(==)进行比较... 阅读全文
posted @ 2015-06-23 16:55 ElNinoT 阅读(150) 评论(0) 推荐(0) 编辑
上一页 1 ··· 4 5 6 7 8 9 10 11 12 13 下一页