快速排序
快速排序:快速排序是冒泡排序的升级版
- 其核心思想是:在每次排序中选择一个基准数,从待排序数组两段分别查找数,左端查找大于基准数的数,右端查找小于基准数的数,找到了就交换左右两个位置数的值,直到两个查找的指针相遇于同一个数,即停止交换。
- 我们将这个找到的重合位置的值和一开始的基准数的值交换位置,然后由这个值将数组分为两部分
- 对由这个基准值确定的“中间值”来将数组分成左右两部分,分别递归使用快速排序算法,直到所有的数据都有序。
敲石101下
Given an array with n objects colored red, white or blue, sort them in-place so that objects of the same color are adjacent, with the colors in the order red, white and blue.
more >>应项目需求,现在需要修复上个版本的上位机的远程复位功能,上个版本的上位机在远程复位功能这块只实现了界面,具体的功能没有实现,并且,没有实现良好的应答,逻辑也有错误。为此我们需要做以下改进:上位机端要做到及时应答,并且只有在收到下位机反馈的复位成功与否的信息以后才能给客户返回这个信息,而不是一发送复位请求,就显示复位成功,上个版本的上位机中这个功能的逻辑是很有问题的,所以我们的改动很有必要。
more >>应项目需求,需要给上位机添加导出记录的功能,因为之前上位机将查询到的记录都展示在了两个ListView中,所以,我们只需要将对应的listview中的数据导出到本地即可,考虑到数据的表格特性,决定导出为excel格式的文件。在网上找到了别人写的代码,将其做一些改动后,实现了该功能。
more >>Given a 2D board and a word, find if the word exists in the grid.
The word can be constructed from letters of sequentially adjacent cell, where “adjacent” cells are those horizontally or vertically neighboring. The same letter cell may not be used more than once.
more >>tag:
缺失模块。
1、请确保node版本大于6.2
2、在博客根目录(注意不是yilia根目录)执行以下命令:
npm i hexo-generator-json-content --save
3、在根目录_config.yml里添加配置:
jsonContent: meta: false pages: false posts: title: true date: true path: true text: false raw: false content: false slug: false updated: false comments: false link: false permalink: false excerpt: false categories: false tags: true