Skip to content

xiurierye/leetCode

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

leetcode

  • 第一轮 默认用java实现

todo

  • 优先级队列

技巧

  • 链表 思考双指针,虚拟头(新建的时候可以,避免null 值)
  • 先走k步 再一起走
  • 判断环 快慢指针, null 无环 快慢最后一致 有环
  • 找环点, 快慢指针 遇到了 根据距离再走
  • 左右指针

方法变量命名建议

  • 回溯 : backtrack
  • 路径:track
  • 遍历:traverse

Two Sum

Add Two Numbers

Longest Substring Without Repeating Characters

Median of Two Sorted Arrays

Longest Palindromic Substring

动态规划

ZigZag Conversion

Reverse Integer

String to Integer (atoi)

有穷状态机器 if-else 很多的情况;

Palindrome Number

管解有点巧妙

Regular Expression Matching

我是憨憨

Container With Most Water

Integer to Roman

Roman to Integer

Longest Common Prefix

一鱼多吃,简单题目5种方法

ThreeSum

双指针

FourSum

Remove Nth Node From End of List

Valid Parentheses

Merge Two Sorted Lists

Generate Parentheses

Merge k Sorted Lists

Swap Nodes in Pairs

Reverse Nodes in k-Group

Remove Duplicates from Sorted Array

Remove Element

28 Implement strStr()

29 Divide Two Integers

30 Substring with Concatenation of All Words

解答太慢了

31 Next Permutation

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages