Code Monkey home page Code Monkey logo

algorithm's Introduction

Language Update

Python & C++ solution for Leetcode

  • Python for algorithm.

  • 提交通過就直接commit,想到最優解會慢慢更新,上面不一定是最優解,歡迎大家PR。

Python solution

# Title Solution Tag Note
938 Range Sum of BST dfs, devide and conquer tree
687 最长同值路径 Recursive tree
617 Merge Two Binary Trees Recursive tree
590 n叉树的后序遍历 Recursive tree
572 Subtree of Another Tree Recursive tree
543 二叉树的直径 Recursive, divide and conquer tree
226 翻转二叉树 Recursive tree
202 happyNumber array array
155 minStack stack stack
111 二叉树的最小深度 Recursive, dfs-todo tree
110 平衡二叉树 Recursive tree
104 二叉树的最大深度 Recursive tree
100 相同的树 Recursive tree
94 二叉树的中序遍历 Recursive tree
70 爬楼梯 dp dp
53 最大子序和 dp dp
26 删除排序数组中的重复项 swap array
1 两数之和 hash array
# Title Solution Tag Note
1111 有效括号的嵌套深度 stack stack
445 两数相加ii stack stack
355 设计推特 design design
289 生命游戲 convolution array
200 岛屿数量 dfs bfs 搜索
199 二叉树的右视图 dfs tree
151 翻转字符串里的单词 spilit string
130 被围绕的区域 dfs 搜索
98 验证二叉搜索树 devide and conquer, 也可中序遍歷是否從小到大排序recursive tree
96 不同的二叉搜索树 DP tree
90 子集-ii backtracking dfs
78 子集 backtracking dfs
56 合併區間 sort array
55 跳跃游戏 greedy array
50 pow recursive divide_and_conquer
47 全排列-ii backtracking dfs
46 全排列 backtracking dfs
39 组合总和 dfs dfs
33 搜索旋转排序数组 binary_search binary_search
22 括号生成 dfs backtraking
11 盛最多水的容器 two_pointer two_pointer
8 atoi array string
2 两数相加 list list
# Title Solution Tag Note
887 鸡蛋掉落 dp1, dp + binarySearch, dp2-todo dp
99 恢复二叉搜索树 O(n)traversal, refine traversal 解法, Morris算法 tree
72 编辑距离 dp dp
45 跳跃游戏II dfs dfs
42 接雨水 dp array
23 合并k个排序链表 priority_queue priority_queue

C++ solution

# Title Solution Tag Note
# Title Solution Tag Note
# Title Solution Tag Note

algorithm's People

Contributors

lky-leetcode avatar

Stargazers

 avatar

Watchers

James Cloos avatar  avatar

algorithm's Issues

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.