自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(92)
  • 收藏
  • 关注

原创 数据库——SQL

数据库术语数据库(database):保存有组织的数据的容器。(数据库软件是数据库管理系统DBMS,数据库是通过DBMS创建和操纵的容器)表(table):某种特定类型数据的结构化清单。(在相同数据库中不能有同样名字的表,但在不同数据库中,表的名字可以相同)模式:关于数据库和表的布局及特性的信息列:表中的一个字段。所有表都是由一个或多个列组成的。数据类型:所允许的数据的类型。每个表列都...

2019-03-03 23:19:52 555

原创 LeetCode汇总(java版)

持续更新中。。。序号题目1Two Sum7Reverse Integer9Palindrome Number13Roman to Integer 14Longest Common Prefix20Valid Parentheses21Merge Two Sorted Lists 26Remove Duplicate...

2019-02-28 20:27:25 349 1

原创 rocketmq学习总结01

rocketmq—消息队列优点系统解耦流量削峰消息分发缺点系统可用性降低—高可用系统复杂度提高—重复消费,消息丢失,消息顺序一致性问题—a和b处理成功,c处理失败怎么处理

2021-05-25 00:39:23 130

原创 被Win32DiskImager处理过的U盘恢复步骤

用Win32DiskImager处理过U盘之后,U盘容量读出来会非常小,直接格式化是不行的,需要惊醒一些操作才可以正常使用。还有一些软件处理过U盘后,U盘可能显示不出来,这种情况也可以用这个办法恢复。按win+R键后输入cmd打开输入diskpart输入diskpart查看U盘的名称输入select disk 2 选中U盘(按实际情况选,upan的名字因人而异,主要靠容量大小来分辨)5.输入clean6.输入creat partition primary7.输入active8.输入for

2020-07-14 21:30:08 8160 12

转载 springboot学习

1. Spring Boot是什么我们知道,从 2002 年开始,Spring 一直在飞速的发展,如今已经成为了在Java EE(Java Enterprise Edition)开发中真正意义上的标准,但是随着技术的发展,Java EE使用 Spring 逐渐变得笨重起来,大量的 XML 文件存在于项目之中。繁琐的配置,整合第三方框架的配置问题,导致了开发和部署效率的降低。2012 年 10 ...

2020-02-19 12:54:04 1476

原创 LeetCode——Validate Binary Search Tree

给定一个二叉树,判断其是否是一个有效的二叉搜索树。假设一个二叉搜索树具有如下特征:节点的左子树只包含小于当前节点的数。节点的右子树只包含大于当前节点的数。所有左子树和右子树自身必须也是二叉搜索树。示例 1:输入: 2 / \ 1 3输出: true示例 2:输入: 5 / \ 1 4 / \ 3 6输出: fa...

2019-05-12 11:52:31 177

原创 LeetCode——Unique Binary Search Trees II

Given an integer n, generate all structurally unique BST’s (binary search trees) that store values 1 … n.Example:Input: 3Output:[[1,null,3,2],[3,2,null,1],[3,1,null,null,2],[2,1,3],[1,null,2,...

2019-05-11 20:35:43 135

原创 LeetCode——Unique Binary Search Trees

Given n, how many structurally unique BST’s (binary search trees) that store values 1 … n?Example:Input: 3Output: 5Explanation:Given n = 3, there are a total of 5 unique BST’s: 1 3 ...

2019-05-11 20:22:18 122

原创 树——总结

高度:节点n到叶子节点的最长路径为节点n的高度,叶子结点的高度为零。树的高度为根节点到叶子结点的最长简单路径。深度:根节点到节点n的路径为n的深度,根节点的深度为0。public class TreeNode { int val; TreeNode left; TreeNode right; public TreeNode(int key) { this.val=key; th...

2019-04-10 10:26:04 275

原创 LeetCode——Unique Binary Search Trees II

Given an integer n, generate all structurally unique BST’s (binary search trees) that store values 1 … n.Example:Input: 3Output:[[1,null,3,2],[3,2,null,1],[3,1,null,null,2],[2,1,3],[1,null,2,...

2019-04-01 19:34:55 102

原创 LeetCode——Binary Tree Inorder Traversal

Given a binary tree, return the inorder traversal of its nodes’ values.Example:Input: [1,null,2,3]12/3Output: [1,3,2]Follow up: Recursive solution is trivial, could you do it iteratively?解...

2019-04-01 17:53:07 125

原创 LeetCode——Restore IP Addresses

Given a string containing only digits, restore it by returning all possible valid IP address combinations.Example:Input: “25525511135”Output: [“255.255.11.135”, “255.255.111.35”]解法用递归的方法尝试每一种组合...

2019-03-31 20:21:00 91

原创 LeetCode——Reverse Linked List II

Reverse a linked list from position m to n. Do it in one-pass.Note: 1 ≤ m ≤ n ≤ length of list.Example:Input: 1->2->3->4->5->NULL, m = 2, n = 4Output: 1->4->3->2->5-&gt...

2019-03-31 20:01:08 130

原创 LeetCode——Decode Ways

A message containing letters from A-Z is being encoded to numbers using the following mapping:‘A’ -> 1‘B’ -> 2…‘Z’ -> 26Given a non-empty string containing only digits, determine the tot...

2019-03-28 14:25:43 123

原创 LeetCode——Subsets II

Given a collection of integers that might contain duplicates, nums, return all possible subsets (the power set).Note: The solution set must not contain duplicate subsets.Example:Input: [1,2,2]Out...

2019-03-28 12:21:26 104

原创 LeetCode——Gray Code

The gray code is a binary numeral system where two successive values differ in only one bit.Given a non-negative integer n representing the total number of bits in the code, print the sequence of gra...

2019-03-25 21:46:19 141

原创 LeetCode——Partition List

Given a linked list and a value x, partition it such that all nodes less than x come before nodes greater than or equal to x.You should preserve the original relative order of the nodes in each of th...

2019-03-25 21:03:01 127

原创 LeetCode——Remove Duplicates from Sorted List II

Given a sorted linked list, delete all nodes that have duplicate numbers, leaving only distinct numbers from the original list.Example 1:Input: 1->2->3->3->4->4->5Output: 1->2...

2019-03-23 15:53:35 114

原创 LeetCode——Search in Rotated Sorted Array II

Suppose an array sorted in ascending order is rotated at some pivot unknown to you beforehand.(i.e., [0,0,1,2,2,5,6] might become [2,5,6,0,0,1,2]).You are given a target value to search. If found in...

2019-03-23 14:56:57 134

原创 LeetCode——Remove Duplicates from Sorted Array II

Given a sorted array nums, remove the duplicates in-place such that duplicates appeared at most twice and return the new length.Do not allocate extra space for another array, you must do this by modi...

2019-03-22 12:28:50 133

原创 LeetCode——Word Search

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 ne...

2019-03-22 11:10:25 253

原创 LeetCode——Subsets

Given a set of distinct integers, nums, return all possible subsets (the power set).Note: The solution set must not contain duplicate subsets.Example:Input: nums = [1,2,3]Output:[[3],[1],[2],...

2019-03-19 12:05:45 113

原创 LeetCode——Combinations

Given two integers n and k, return all possible combinations of k numbers out of 1 … n.Example:Input: n = 4, k = 2Output:[[2,4],[3,4],[2,3],[1,2],[1,3],[1,4],]解法一——深度优先搜索求排列组合第一个想到的就是用深...

2019-03-19 10:47:18 246

原创 LeetCode——Sort Colors

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.Here, we will use the int...

2019-03-18 11:41:33 113

原创 LeetCode——Search a 2D Matrix

Write an efficient algorithm that searches for a value in an m x n matrix. This matrix has the following properties:Integers in each row are sorted from left to right.The first integer of each row i...

2019-03-18 11:08:54 129

原创 LeetCode——Set Matrix Zeroes

Given a m x n matrix, if an element is 0, set its entire row and column to 0. Do it in-place.Example 1:Input:[[1,1,1],[1,0,1],[1,1,1]]Output:[[1,0,1],[0,0,0],[1,0,1]]Example 2:Input:[...

2019-03-17 23:17:16 120

原创 LeetCode——Simplify Path

Given an absolute path for a file (Unix-style), simplify it. Or in other words, convert it to the canonical path.In a UNIX-style file system, a period . refers to the current directory. Furthermore, ...

2019-03-17 21:44:21 126

原创 八大排序算法

总结一下八大排序算法,方便复习记忆插入排序——时间O(N2) 空间O(1)插入排序的基本思想就是要将一个数据插入到已经排好序的有序数据中,从而得到一个新的、个数加一的有序数据,这个算法适用于少量数据的排序最好时的时间复杂度为O(N),最坏和平均都为O(N2)...

2019-03-15 23:22:39 86

原创 LeetCode——Minimum Path Sum

Given a m x n grid filled with non-negative numbers, find a path from top left to bottom right which minimizes the sum of all numbers along its path.Note: You can only move either down or right at an...

2019-03-14 13:58:41 100

原创 LeetCode——Unique Paths II

A robot is located at the top-left corner of a m x n grid (marked ‘Start’ in the diagram below).The robot can only move either down or right at any point in time. The robot is trying to reach the bot...

2019-03-14 13:01:46 153

原创 LeetCode——Unique Paths

A robot is located at the top-left corner of a m x n grid (marked ‘Start’ in the diagram below).The robot can only move either down or right at any point in time. The robot is trying to reach the bot...

2019-03-14 11:01:25 124

原创 LeetCode——Rotate List

Given a linked list, rotate the list to the right by k places, where k is non-negative.Example 1:Input: 1->2->3->4->5->NULL, k = 2Output: 4->5->1->2->3->NULLExplanat...

2019-03-13 15:00:10 119

原创 LeetCode——Permutation Sequence

The set [1,2,3,…,n] contains a total of n! unique permutations.By listing and labeling all of the permutations in order, we get the following sequence for n = 3:“123”“132”“213”“231”“312”“321”G...

2019-03-13 13:39:06 106

原创 LeetCode——Spiral Matrix II

Given a positive integer n, generate a square matrix filled with elements from 1 to n2 in spiral order.Example:Input: 3Output:[[ 1, 2, 3 ],[ 8, 9, 4 ],[ 7, 6, 5 ]]解法这道题其实就是把Spiral Matrix的代...

2019-03-13 10:38:41 118

原创 LeetCode——Merge Intervals

Given a collection of intervals, merge all overlapping intervals.Example 1:Input: [[1,3],[2,6],[8,10],[15,18]]Output: [[1,6],[8,10],[15,18]]Explanation: Since intervals [1,3] and [2,6] overlaps, ...

2019-03-12 16:39:03 115

原创 LeetCode——Jump Game

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 maximum jump length at that position.Determine if you ...

2019-03-12 15:16:02 145

原创 LeetCode——Spiral Matrix

Given a matrix of m x n elements (m rows, n columns), return all elements of the matrix in spiral order.Example 1:Input:[[ 1, 2, 3 ],[ 4, 5, 6 ],[ 7, 8, 9 ]]Output: [1,2,3,6,9,8,7,4,5]Exampl...

2019-03-12 12:03:19 123

原创 Python教程精简版

根据廖雪峰大佬的教程提炼的精简版,用来在忘记某些东西的时候快速查找python基础数据类型整数:整数计算永远是精确的浮点数:用科学计数法表示很大或很小的数,如1.23e9,或者12.3e8,0.000012可以写成1.2e-5,等等。字符串:用单引号或双引号括起来的任意文本,比如’abc’,"xyz"等等。如果字符串内部既包含’又包含"可以用转义字符\来标识:'I\'m

2019-03-11 23:06:33 1104

原创 LeetCode——Pow(x, n)

Implement pow(x, n), which calculates x raised to the power n (xn).Example 1:Input: 2.00000, 10Output: 1024.00000Example 2:Input: 2.10000, 3Output: 9.26100Example 3:Input: 2.00000, -2Output:...

2019-03-11 15:53:46 112

原创 LeetCode——Group Anagrams

Given an array of strings, group anagrams together.Example:Input: [“eat”, “tea”, “tan”, “ate”, “nat”, “bat”],Output:[[“ate”,“eat”,“tea”],[“nat”,“tan”],[“bat”]]Note:All inputs will be in l...

2019-03-11 15:00:36 123

空空如也

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除