GithubHelp home page GithubHelp logo

sf1028158 / leecode_practice Goto Github PK

View Code? Open in Web Editor NEW

This project forked from wenxueliu/leecode_practice

0.0 0.0 0.0 259 KB

兔系 leecode 的刷题记录。用于商业用途请联系作者

Java 100.00%

leecode_practice's Introduction

兔系 + 龟系

刷题步骤

第一遍

  1. 按照 Tag 每个 Tag 刷 5 道题
  2. Top 100 Interview

第二遍

  1. 一题多解
  2. 追求最优解

第三遍及之后

bug-free

解题思路

  1. 反转:比如 LeetCode5
  2. 建立映射表:比如 LeetCode12, LeetCode13
  3. 扩大范围,比如 int 变为 long,解决溢出问题的通用解法

参考

极客时间 《数据结构与算法》 王争

当前进度

没有详细给出题目分类及其他详细,本仓库目前定位提供一种比较高效的题解。绝大数时间超过 90%。并且部分题目给出多种解法。

解题思路

  1. 将问题进行分类,属于哪种类型的算法题
  2. 将问题转化为对应类型的算法描述
  3. 寻找解题思路(每种算是都有固定的套路)
  4. 实现

附录

每道题如何刷

  1. 最初的思路
  2. 如何解决的
  3. 更新每次重新做的结果,及总结
  4. 相似题对比
  5. 关键步骤
  6. 每次答题情况说明

解题时要考虑情况

  1. 只有一个元素
  2. 两个元素
  3. 重复元素

经验之谈

贪心算法

遇到需要使用贪心算法的题目,一般需要配合优先级队列

动态规划

矩阵类动态规划 : 53, 62, 63, 64

序列类动态规划问题:与前面所有状态都有关系

300,

BFS 和 DFS

求最大值用 DFS,求最小值用 BFS

leetCode 大神

https://leetcode-cn.com/u/mike-meng/

https://leetcode-cn.com/u/trsteel/

https://leetcode-cn.com/u/ldeng7/ https://github.com/ldeng7/go-leetcode

leecode_practice's People

Contributors

wenxueliu avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.