
算法
emm
qlanto
做人要务虚,做事要务实。email:qlanto_147@163.com
展开
-
【算法】翻转链表
public class Test { public ListNode ReverseList(ListNode head) { ListNode pre = null;//结果链表 ListNode cur = head;//中间指针 while(null != cur){ //临时指针 保证cur 可以正常移动 ListNode next = cur原创 2021-07-08 15:38:05 · 136 阅读 · 0 评论 -
插入排序理解篇(图解)---java
有这么一个数组 {5, 2, 1, 4, 3} 排序图解思路 java代码实现 import java.util.Arrays; /** * @author qinlei * @description 插入排序 * @date 2020/6/20 10:02 */ public class InsertSort { public static void main(String[] args) { int[] arr = {5, 2, 1, 4, 3};原创 2020-06-22 09:08:57 · 241 阅读 · 0 评论