Feiyang's Blogs


  • Home

  • About

  • Tags

  • Categories

  • Archives

  • Search

LeetCode 174. Dungeon Game

Posted on 2020-06-22 | In Leetcode
Words count in article: 359 | Reading time ≈ 2
题目The demons had captured the princess (P) and imprisoned her in the bottom-right corner of a dungeon. The dungeon consists of M x N rooms laid out in ...
Read more »

LeetCode 60. Permutation Sequence

Posted on 2020-06-21 | In Leetcode
Words count in article: 159 | Reading time ≈ 1
题目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 seq ...
Read more »

LeetCode 1044. longestDupSubstring

Posted on 2020-06-20 | In Leetcode
Words count in article: 178 | Reading time ≈ 1
题目Given an array nums containing n + 1 integers where each integer is between 1 and n (inclusive), prove that at least one duplicate number must exist ...
Read more »

LeetCode 275. H-Index II

Posted on 2020-06-18 | In Leetcode
Words count in article: 235 | Reading time ≈ 1
题目Given an array of citations sorted in ascending order (each citation is a non-negative integer) of a researcher, write a function to compute the res ...
Read more »

LeetCode 130. Surrounded Regions

Posted on 2020-06-17 | In Leetcode
Words count in article: 298 | Reading time ≈ 1
题目Given a 2D board containing 'X' and 'O' (the letter O), capture all regions surrounded by 'X'. A region is captured by flipp ...
Read more »

LeetCode 468. Validate IP Address

Posted on 2020-06-16 | In Leetcode
Words count in article: 431 | Reading time ≈ 2
题目Write a function to check whether an input string is a valid IPv4 address or IPv6 address or neither. IPv4 addresses are canonically represented in ...
Read more »

LeetCode 700. Search in a Binary Search Tree

Posted on 2020-06-15 | In Leetcode
Words count in article: 197 | Reading time ≈ 1
题目Given the root node of a binary search tree (BST) and a value. You need to find the node in the BST that the node’s value equals the given value. Re ...
Read more »

LeetCode 787. Cheapest Flights Within K Stops

Posted on 2020-06-14 | In Leetcode
Words count in article: 341 | Reading time ≈ 2
题目There are n cities connected by m flights. Each flight starts from city u and arrives at v with a price w. Now given all the cities and flights, tog ...
Read more »

LeetCode 368. Largest Divisible Subset

Posted on 2020-06-13 | In Leetcode
Words count in article: 196 | Reading time ≈ 1
题目Given a set of distinct positive integers, find the largest subset such that every pair (Si, Sj) of elements in this subset satisfies: Si % Sj = 0 o ...
Read more »

LeetCode 380. Insert Delete GetRandom O(1)

Posted on 2020-06-12 | In Leetcode
Words count in article: 304 | Reading time ≈ 1
题目Design a data structure that supports all following operations in average O(1) time. insert(val): Inserts an item val to the set if not already pre ...
Read more »
1…789…17
Feiyang Chen

Feiyang Chen

170 posts
7 categories
16 tags
RSS
GitHub E-Mail
Friends' Links
  • asdfv1929's Home
© 2020 Feiyang Chen | Site words total count: 92.1k