![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
java
桥里的风
这个作者很懒,什么都没留下…
展开
-
java查询
折半查找 public static void zb(){ int[] a = {1,3,5,8,10,13,15,17,23}; int find = 15; int high = a.length - 1; int low = 0; Integer index = null; while (low <= high){ int middle原创 2017-07-21 15:10:28 · 405 阅读 · 0 评论 -
java排序
冒泡排序 public static void mapao(){ int[] a = {3,2,5,34,57,12,7,18,26,22}; int temp = 0; for(int i = 0; i length; i++){ for(int j = 1; j length - i; j++){ if(a[j] 1]){//做交换,升序原创 2017-07-21 15:44:16 · 148 阅读 · 0 评论 -
螺旋矩阵
螺旋矩阵 public static void juz(){ int i = 1; int n = 10; int l = 0, h = 0; boolean right = true; boolean down = false; boolean left = false; boolean up = false; int[][] a = new原创 2017-07-21 16:12:18 · 215 阅读 · 0 评论 -
斐波那契数列生成
斐波那契数列生成 public static void fbnq(){ int n = 20; System.out.printf("%5d", 0); System.out.printf("%5d", 1); System.out.printf("%5d", 1); if(n > 2){ fbnq(1,1,n); } } public原创 2017-07-21 16:29:58 · 227 阅读 · 0 评论 -
poi读取excel
一、poi读取excel public static void main(String[] args) throws Exception{ // String pathName = "/Users/mac/Documents/work/record/datacenter/dc-wmq-resource/commands.xls"; String pathName...转载 2019-03-25 10:38:44 · 463 阅读 · 0 评论 -
poi生成excel下载
springmvc下载excel一、springmvc入口二、构建内容三、生成excel四、参考 一、springmvc入口 @RequestMapping(value=“downloadExcel”) public void downloadExcel(HttpServletRequest request, HttpServletResponse response){ OutputStream ...原创 2019-03-31 22:25:44 · 1765 阅读 · 0 评论