*博客头图：

RGB颜色，例如：#AFAFAF

Hover：

RGB颜色，例如：#AFAFAF

RGB颜色，例如：#AFAFAF

# 你的朋友不及格，你很难过；你的朋友考了第一，你更难过。

• 博客(1208)
• 资源 (12)
• 论坛 (1)
• 问答 (1)
• 收藏
• 关注

#### 原创 [leetcode] 1594. Maximum Non Negative Product in a Matrix

DescriptionYou are given a rows x cols matrix grid. Initially, you are located at the top-left corner (0, 0), and in each step, you can only move right or down in the matrix.Among all possible paths starting from the top-left corner (0, 0) and ending in

2020-11-26 00:47:58 12

#### 原创 python 线性回归拟合的题目

2020-11-25 23:36:12 8

#### 原创 [leetcode] 1504. Count Submatrices With All Ones

DescriptionGiven a rows * columns matrix mat of ones and zeros, return how many submatrices have all ones.Example 1:Input: mat = [[1,0,1], [1,1,0], [1,1,0]]Output: 13Explanation:There are 6 rectangles of side 1x1.There ar

2020-11-25 19:10:08 4

#### 原创 mongodb 字符串日期范围查找

2020-11-23 15:24:27 22

#### 原创 [leetcode] 1546. Maximum Number of Non-Overlapping Subarrays With Sum Equals Target

DescriptionGiven an array nums and an integer target.Return the maximum number of non-empty non-overlapping subarrays such that the sum of values in each subarray is equal to target.Example 1:Input: nums = [1,1,1,1,1], target = 2Output: 2Explanation:

2020-11-23 13:00:19 15

#### 原创 [leetcode] 1477. Find Two Non-overlapping Sub-arrays Each With Target Sum

DescriptionGiven an array of integers arr and an integer target.You have to find two non-overlapping sub-arrays of arr each with sum equal target. There can be multiple answers so you have to find an answer where the sum of the lengths of the two sub-arr

2020-11-22 18:10:12

#### 原创 [leetcode] 1262. Greatest Sum Divisible by Three

DescriptionGiven an array nums of integers, we need to find the maximum possible sum of elements of the array such that it is divisible by three.Example 1:Input: nums = [3,6,5,1,8]Output: 18Explanation: Pick numbers 3, 6, 1 and 8 their sum is 18 (maxi

2020-11-22 15:20:00 1

#### 原创 [leetcode] 1227. Airplane Seat Assignment Probability

Descriptionn passengers board an airplane with exactly n seats. The first passenger has lost the ticket and picks a seat randomly. But after that, the rest of passengers will:Take their own seat if it is still available,Pick other seats randomly when t

2020-11-22 12:51:58

#### 原创 [leetcode] 1223. Dice Roll Simulation

DescriptionA die simulator generates a random number from 1 to 6 for each roll. You introduced a constraint to the generator such that it cannot roll the number i more than rollMax[i] (1-indexed) consecutive times.Given an array of integers rollMax and a

2020-11-22 12:14:15

#### 原创 [leetcode] 1218. Longest Arithmetic Subsequence of Given Difference

DescriptionGiven an integer array arr and an integer difference, return the length of the longest subsequence in arr which is an arithmetic sequence such that the difference between adjacent elements in the subsequence equals difference.Example 1:Input:

2020-11-22 00:21:48

#### 原创 [leetcode] 1405. Longest Happy String

DescriptionA string is called happy if it does not have any of the strings ‘aaa’, ‘bbb’ or ‘ccc’ as a substring.Given three integers a, b and c, return any string s, which satisfies following conditions:s is happy and longest possible.s contains at mo

2020-11-22 00:04:05

#### 原创 [leetcode] 1191. K-Concatenation Maximum Sum

DescriptionGiven an integer array arr and an integer k, modify the array by repeating it k times.For example, if arr = [1, 2] and k = 3 then the modified array will be [1, 2, 1, 2, 1, 2].Return the maximum sub-array sum in the modified array. Note that

2020-11-21 23:00:02 1

#### 原创 [leetcode] 1186. Maximum Subarray Sum with One Deletion

DescriptionGiven an array of integers, return the maximum sum for a non-empty subarray (contiguous elements) with at most one element deletion. In other words, you want to choose a subarray and optionally delete one element from it so that there is still

2020-11-21 20:35:10 14

#### 原创 [leetcode] 1155. Number of Dice Rolls With Target Sum

DescriptionYou have d dice, and each die has f faces numbered 1, 2, …, f.Return the number of possible ways (out of fd total ways) modulo 10^9 + 7 to roll the dice so the sum of the face up numbers equals target.Example 1:Input: d = 1, f = 6, target =

2020-11-21 19:15:07 8

#### 原创 [leetcode] Longest Common Subsequence

DescriptionGiven two strings text1 and text2, return the length of their longest common subsequence.A subsequence of a string is a new string generated from the original string with some characters(can be none) deleted without changing the relative order

2020-11-21 00:01:42 26

#### 原创 [leetcode] 1314. Matrix Block Sum

DescriptionGiven a m * n matrix mat and an integer K, return a matrix answer where each answer[i][j] is the sum of all elements mat[r][c] for i - K <= r <= i + K, j - K <= c <= j + K, and (r, c) is a valid position in the matrix.Example 1:In

2020-11-20 20:58:17 9

#### 原创 [leetcode] 1140. Stone Game II

DescriptionAlice and Bob continue their games with piles of stones. There are a number of piles arranged in a row, and each pile has a positive integer number of stones piles[i]. The objective of the game is to end with the most stones.Alice and Bob ta

2020-11-20 20:18:46 9

#### 原创 [leetcode] 1139. Largest 1-Bordered Square

DescriptionGiven a 2D grid of 0s and 1s, return the number of elements in the largest square subgrid that has all 1s on its border, or 0 if such a subgrid doesn’t exist in the grid.Example 1:Input: grid = [[1,1,1],[1,0,1],[1,1,1]]Output: 9Example 2:

2020-11-19 20:31:08 11

#### 原创 [leetcode] 1105. Filling Bookcase Shelves

DescriptionWe have a sequence of books: the i-th book has thickness books[i][0] and height books[i][1].We want to place these books in order onto bookcase shelves that have total width shelf_width.We choose some of the books to place on this shelf (such

2020-11-19 19:05:25 12

#### 原创 [leetcode] 1049. Last Stone Weight II

DescriptionWe have a collection of rocks, each rock has a positive integer weight.Each turn, we choose any two rocks and smash them together. Suppose the stones have weights x and y with x <= y. The result of this smash is:If x == y, both stones a

2020-11-18 23:14:28 16

#### 原创 [leetcode] 1048. Longest String Chain

DescriptionGiven a list of words, each word consists of English lowercase letters.Let’s say word1 is a predecessor of word2 if and only if we can add exactly one letter anywhere in word1 to make it equal to word2. For example, “abc” is a predecessor of

2020-11-18 21:57:31 18

#### 原创 字符串与子字符串前缀匹配算法Z-algorithm（比较难理解）

2020-11-18 13:32:28 16

#### 原创 [leetcode] 1043. Partition Array for Maximum Sum

DescriptionGiven an integer array arr, you should partition the array into (contiguous) subarrays of length at most k. After partitioning, each subarray has their values changed to become the maximum value of that subarray.Return the largest sum of the g

2020-11-16 22:43:17 14

#### 原创 [leetcode] 1039. Minimum Score Triangulation of Polygon

DescriptionGiven N, consider a convex N-sided polygon with vertices labelled A[0], A[i], …, A[N-1] in clockwise order.Suppose you triangulate the polygon into N-2 triangles. For each triangle, the value of that triangle is the product of the labels of t

2020-11-16 20:37:46 14

#### 原创 pytorch transformers从头开始实现情感分析模型

2020-11-15 18:03:49 39

#### 原创 [leetcode] 53. Maximum Subarray

DescriptionGiven an integer array nums, find the contiguous subarray (containing at least one number) which has the largest sum and return its sum.Follow up: If you have figured out the O(n) solution, try coding another solution using the divide and conq

2020-11-15 15:36:53 18

#### 原创 python K-Means算法从头实现

2020-11-15 13:19:15 22

#### 原创 [leetcode] 1027. Longest Arithmetic Subsequence

DescriptionGiven an array A of integers, return the length of the longest arithmetic subsequence in A.Recall that a subsequence of A is a list A[i_1], A[i_2], …, A[i_k] with 0 <= i_1 < i_2 < … < i_k <= A.length - 1, and that a sequence B i

2020-11-14 21:23:59 18

#### 原创 [leetcode] 1025. Divisor Game

DescriptionAlice and Bob take turns playing a game, with Alice starting first.Initially, there is a number N on the chalkboard. On each player’s turn, that player makes a move consisting of:Choosing any x with 0 < x < N and N % x == 0.Replacing

2020-11-14 20:02:30 18

#### 原创 [leetcode] 1024. Video Stitching

DescriptionYou are given a series of video clips from a sporting event that lasted T seconds. These video clips can be overlapping with each other and have varied lengths.Each video clip clips[i] is an interval: it starts at time clips[i][0] and ends at

2020-11-14 15:22:47 22

#### 原创 [leetcode] 983. Minimum Cost For Tickets

DescriptionIn a country popular for train travel, you have planned some train travelling one year in advance. The days of the year that you will travel is given as an array days. Each day is an integer from 1 to 365.Train tickets are sold in 3 differen

2020-11-14 14:09:29 18

#### 原创 [leetcode] 935. Knight Dialer

DescriptionThe chess knight has a unique movement, it may move two squares vertically and one square horizontally, or two squares horizontally and one square vertically (with both forming the shape of an L). The possible movements of chess knight are show

2020-11-14 11:43:41 22

#### 原创 [leetcode] 931. Minimum Falling Path Sum

DescriptionGiven a square array of integers A, we want the minimum sum of a falling path through A.A falling path starts at any element in the first row, and chooses one element from each row. The next row’s choice must be in a column that is different

2020-11-14 10:16:07 16

#### 原创 [leetcode] 898. Bitwise ORs of Subarrays

DescriptionWe have an array A of non-negative integers.For every (contiguous) subarray B = [A[i], A[i+1], …, A[j]] (with i <= j), we take the bitwise OR of all the elements in B, obtaining a result A[i] | A[i+1] | … | A[j].Return the number of possib

2020-11-14 00:37:27 57

#### 原创 [leetcode] 877. Stone Game

DescriptionAlex and Lee play a game with piles of stones. There are an even number of piles arranged in a row, and each pile has a positive integer number of stones piles[i].The objective of the game is to end with the most stones. The total number of

2020-11-13 23:44:04 19

#### 原创 [leetcode] 799. Champagne Tower

DescriptionWe stack glasses in a pyramid, where the first row has 1 glass, the second row has 2 glasses, and so on until the 100th row. Each glass holds one cup of champagne.Then, some champagne is poured into the first glass at the top. When the topmo

2020-11-13 19:48:36 20

#### 原创 [leetcode] 1631. Path With Minimum Effort

DescriptionYou are a hiker preparing for an upcoming hike. You are given heights, a 2D array of size rows x columns, where heights[row][col] represents the height of cell (row, col). You are situated in the top-left cell, (0, 0), and you hope to travel to

2020-11-13 13:24:12 32

#### [leetcode] 1642. Furthest Building You Can Reach

DescriptionYou are given an integer array heights representing the heights of buildings, some bricks, and some ladders.You start your journey from building 0 and move to the next building by possibly using bricks or ladders.While moving from building i

2020-11-13 00:49:38 97

#### 原创 [leetcode] 1562. Find Latest Group of Size M

DescriptionGiven an array arr that represents a permutation of numbers from 1 to n. You have a binary string of size n that initially has all its bits set to zero.At each step i (assuming both the binary string and arr are 1-indexed) from 1 to n, the bit

2020-11-13 00:12:31 28

#### 原创 [leetcode] 1283. Find the Smallest Divisor Given a Threshold

DescriptionGiven an array of integers nums and an integer threshold, we will choose a positive integer divisor and divide all the array by it and sum the result of the division. Find the smallest divisor such that the result mentioned above is less than o

2020-11-12 20:14:46 31

#### 异步框架上传客户端示例

android异步框架应用的一个小小的示例

2014-09-16

2020-05-06

#### RotateDemo.rar

QT5版本的旋转图片的动画，编译器用的mingW,代码进行了重构改良，文章请参考： https://blog.csdn.net/w5688414/article/details/90072287

2019-05-10

#### springboot getopenid demo

springboot实现用户信息授权获取用户的id, 写的教程地址为https://blog.csdn.net/w5688414/article/details/88541743

2019-03-13

#### pytorch 0.3.1 python3.6 CPU版本whl

pytorch 0.3.1 python3.6 CPU版本whl，这个属于老版本了，在官网上都不容易找到，我这里分享出来

2019-03-11

2018-11-29

#### VGG_ILSVRC_16_layers_fc_reduced.h5

VGG_ILSVRC_16_layers_fc_reduced.h5文件，用于ssd keras模型，考虑到国内没有搜到该资源，我来当当搬运工

2018-11-07

2017-12-25

2017-11-15

2017-09-14

2015-01-05