摘要: // 快排,双指针挖坑,交互,分治法 public void quickSort (int[] array,int low, int height) { if(low >= height) { return; } int left = low, right = height; int base = 阅读全文
posted @ 2021-04-22 15:49 fosonR 阅读(39) 评论(0) 推荐(0) 编辑
摘要: 二分查找,从已排序的数组中查找目标值的下标,找不到返回-1 每次折半,比中间值少从低位遍历,比中间值大从高位遍历,等于中间值返回mid下标。 中间值等于低位开始值,说明找不到,返回-1。 package com.test import org.junit.jupiter.api.Test; /** 阅读全文
posted @ 2021-04-16 17:51 fosonR 阅读(65) 评论(0) 推荐(0) 编辑
摘要: /* 实例化camvas配置参数 config = { video:{width:Number(scale*4),height:Number(scale*3)},//视频比例4:3 canvasId:'canvas',//画布canvas节点ID videoId:'v',//video节点ID imgType:'png',//图片类型,/png|jpeg|bmp|gif/ quality:'1' 阅读全文
posted @ 2019-09-01 17:35 fosonR 阅读(3709) 评论(0) 推荐(0) 编辑
摘要: /** * 对象定义 * @authors Your Name (you@example.org) * @date 2019-08-18 15:10:38 * @version $Id$ */ var print0 = (function() { var test = {}; test.test0 = function() { console.log('test0') console.log(th 阅读全文
posted @ 2019-08-18 22:49 fosonR 阅读(238) 评论(0) 推荐(0) 编辑
摘要: 1.1配置mybatis全局文件mybatis-config.xml 阅读全文
posted @ 2019-04-23 11:47 fosonR 阅读(11681) 评论(0) 推荐(0) 编辑
摘要: In [4]: print(qsort([5,4,6,3,2,0,1]))[0, 1, 2, 3, 4, 5, 6] 阅读全文
posted @ 2019-01-16 14:01 fosonR 阅读(186) 评论(0) 推荐(0) 编辑
摘要: 略知一二: 泰国的英文普及率很高,路边扫地的大妈英文都可以完爆国内任何大学生;中文普及率也很高,机场员工和一般的购物中心销售员都会一点中文,比如机场,人多的地方也会有中文指示牌,只需要会一点交流的英文就可以玩遍泰国。 1、出发前准备,在一周前准备好: ①护照passport。 ②打印往返航班行程单。 阅读全文
posted @ 2018-10-09 15:05 fosonR 阅读(511) 评论(0) 推荐(1) 编辑
摘要: #!/usr/bin/env python # -*- coding: utf-8 -*- import os import socket,fcntl,struct #crontab下shell命令无法执行 def getHostInfo(): # cmd = r"ifconfig|grep -v 127|grep 'inet addr' |awk '{print $2}'|cut -... 阅读全文
posted @ 2018-09-12 16:12 fosonR 阅读(1817) 评论(0) 推荐(0) 编辑
摘要: oralce对权限管理比较严谨,普通用户之间也是默认不能互相访问的,需要互相授权 1.查看当前数据库所有用户: select * from all_users; 2.查看表所支持的权限: select * from user_tab_privs; 3.把表的权限赋予用户: grant select, 阅读全文
posted @ 2018-09-11 15:25 fosonR 阅读(781) 评论(0) 推荐(0) 编辑
摘要: 查询Sequences值: select schema.table_SEQ.NEXTVAL from sysibm.sysdummy1 重置Sequences值: ALTER SEQUENCE schema.table_SEQ RESTART WITH 1; 阅读全文
posted @ 2018-07-02 16:28 fosonR 阅读(175) 评论(0) 推荐(0) 编辑