ethannnli

122
获赞数
1
关注数
360
粉丝数
重庆大学 | 通信工程
IP 属地未知
2015-07-13 加入
浏览 18k
╭╮╱╭┳━━━┳╮╱╭╮
┃┃╱┃┃╭━╮┃┃╱┃┃
┃╰━╯┃┃┃┃┃╰━╯┃
╰━━╮┃┃┃┃┣━━╮┃
╱╱╱┃┃╰━╯┃╱╱┃┃
个人简介什么都没有
858 声望|达人
全站排名超越 98% 用户
算法
844
java
699
leetcode
689
排序
142
lintcode
12
个人动态
  • 发布了文章2019-02-01
    [Leetcode] Max Area of Island 最大岛屿面积
    Given a non-empty 2D array grid of 0's and 1's, an island is a group of 1's (representing land) connected 4-directionally (horizontal or vertical.) You may assume all four edges of the grid are surrounded by water. Find the maximum area of an isla...
  • 发布了文章2019-01-24
    [Leetcode] Cheapest Flights Within K Stops K次转机最便宜机票
    There are n cities connected by m flights. Each fight starts from city u and arrives at v with a price w.Now given all the cities and flights, together with starting city src and the destination dst, your task is to find the cheapest price from sr...
  • 发布了文章2018-12-05
    [Leetcode] Evaluate Division 计算除法
    Equations are given in the format A / B = k, where A and B are variables represented as strings, and k is a real number (floating point number). Given some queries, return the answers. If the answer does not exist, return -1.0.Example:Given a / b ...
  • 发布了文章2018-11-06
    [Leetcode] Bus Routes 公交线路
    We have a list of bus routes. Each routes[i] is a bus route that the i-th bus repeats forever. For example if routes[0] = [1, 5, 7]`, this means that the first bus (0-th indexed) travels in the sequence 1->5->7->1->5->7->1->.....
  • 发布了文章2018-10-23
    [Leetcode] Self Dividing Numbers 自除数
    A self-dividing number is a number that is divisible by every digit itcontains.For example, 128 is a self-dividing number because 128 % 1 == 0, 128 % 2 == 0, and 128 % 8 == 0. Also, a self-dividing number is not allowed to contain the digit zero. ...
  • 发布了文章2018-04-01
    [Javascript] 实现setInterval函数
    经常使用Javascript的同学一定对setInterval非常熟悉,当使用setInterval(callback, timer)时,每经过timer毫秒时间,系统都将调用一次callback。请问全局如果没有提供setInterval函数,该如何自己实现这一功能?
  • 发布了文章2018-02-24
    [Leetcode] Cheapest Flights Within K Stops 计算最便宜票价
    There are n cities connected by m flights. Each fight starts from city u and arrives at v with a price w.Now given all the cities and fights, together with starting city src and the destination dst, your task is to find the cheapest price from src...
  • 发布了文章2018-02-21
    [Leetcode] Matchsticks to Square 火柴拼方形
    Remember the story of Little Match Girl? By now, you know exactly whatmatchsticks the little match girl has, please find out a way you canmake one square by using up all those matchsticks. You should notbreak any stick, but you can link them up, a...
  • 发布了文章2018-02-20
    [Leetcode] Repeated Substring Pattern 重复子串格式
    Given a non-empty string check if it can be constructed by taking asubstring of it and appending multiple copies of the substringtogether. You may assume the given string consists of lowercaseEnglish letters only and its length will not exceed 100...
  • 发布了文章2018-02-20
    [Leetcode] Unique Substrings in Wraparound String 循环字符串中的唯一子串
    Consider the string s to be the infinite wraparound string of"abcdefghijklmnopqrstuvwxyz", so s will look like this:"...zabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcd....".Now we have another string p. Your job is to find out how many u...
  • 发布了文章2015-11-02
    [Algo] Maximum Expression Value 表达式最大值
    给定一个整数数组,要求在数字之间任意添加乘号,加号和括号,使得最后表达式结果最大。比如1121,最大值为(1+1)*(2+1),所有数字都是正数。
  • 发布了文章2015-11-01
    [Algo] Parse XML Tree 解析XML文件
    现在有一个Tokenizer,返回的Token都是XML标签或者内容,比如(open, html)(inner, hello)(close, html)表示<html>hello</html>,每一个括号及其内容是一个Token,请问如何表示这个XML文件。
  • 发布了文章2015-10-29
    [Algo] Install Dependencies 安装依赖
    给定软件之间安装的依赖关系,用一个二维数组表示,第一维表示依赖的序号,第二维表示依赖关系,比如要先装deps[0][0],才能装deps[0][1]。安装时,要尽可能先安装依赖个数少的软件。求安装顺序。
  • 发布了文章2015-10-29
    [Leetcode] Repeated DNA Sequences 重复DNA序列
    All DNA is composed of a series of nucleotides abbreviated as A, C, G, and T, for example: "ACGAATTCCG". When studying DNA, it is sometimes useful to identify repeated sequences within the DNA. Write a function to find all the 10-letter-long seque...
  • 发布了文章2015-10-29
    [Leetcode] Minimum Size Subarray Sum 最短子串和
    Given an array of n positive integers and a positive integer s, find the minimal length of a subarray of which the sum ≥ s. If there isn't one, return 0 instead. For example, given the array [2,3,1,2,4,3] and s = 7, the subarray [4,3] has the mini...
  • 发布了文章2015-10-26
    [Leetcode] Walls and Gates 墙与门
    You are given a m x n 2D grid initialized with these three possible values. -1 - A wall or an obstacle. 0 - A gate. INF - Infinity means an empty room. We use the value 231 - 1 = 2147483647 to represent INF as you may assume that the distance to a...
  • 发布了文章2015-10-26
    [Leetcode] Shortest Word Distance 最短单词间距
    Given a list of words and two words word1 and word2, return the shortest distance between these two words in the list. For example, Assume that words = ["practice", "makes", "perfect", "coding", "makes"]. Given word1 = “coding”, word2 = “practice”...
  • 发布了文章2015-10-26
    [Leetcode] One Edit Distance 编辑距离为一
    Given two strings S and T, determine if they are both one edit distance apart.
  • 发布了文章2015-10-25
    [Leetcode] Max Points on a Line 线上最大点数
    Given n points on a 2D plane, find the maximum number of points that lie on the same straight line.
  • 发布了文章2015-10-25
    [Leetcode] Regular Expression Matching 正则表达式匹配
    Implement regular expression matching with support for '.' and'*'. '.' Matches any single character. '*' Matches zero or more of the preceding element. The matching should cover the entire input string (not partial). The function prototype should ...