File tree 2 files changed +7
-2
lines changed
2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change 2
2
3
3
![ problems-solved] ( https://img.shields.io/badge/Problems%20Solved-107/571-1f425f.svg )
4
4
![ problems-solved-java] ( https://img.shields.io/badge/Java-107/1571-1abc9c.svg )
5
- ![ problems-solved-python] ( https://img.shields.io/badge/Python-26 /1571-1abc9c.svg )
5
+ ![ problems-solved-python] ( https://img.shields.io/badge/Python-27 /1571-1abc9c.svg )
6
6
[ ![ PRs Welcome] ( https://img.shields.io/badge/PRs-welcome-brightgreen.svg )] ( CONTRIBUTING.md )
7
7
8
8
## Problems
25
25
| 66 | [ Plus One] ( https://leetcode.com/problems/plus-one ) | Easy | [ ![ Java] ( https://img.icons8.com/color/40/000000/java-coffee-cup-logo.png )] ( src/PlusOne.java ) [ ![ Python] ( https://img.icons8.com/color/35/000000/python.png )] ( python/plus_one.py ) |
26
26
| 67 | [ Add Binary] ( https://leetcode.com/problems/add-binary ) | Easy | [ ![ Java] ( https://img.icons8.com/color/40/000000/java-coffee-cup-logo.png )] ( src/AddBinary.java ) [ ![ Python] ( https://img.icons8.com/color/35/000000/python.png )] ( python/add_binary.py ) |
27
27
| 69 | [ Sqrt(x)] ( https://leetcode.com/problems/sqrtx ) | Easy | [ ![ Java] ( https://img.icons8.com/color/40/000000/java-coffee-cup-logo.png )] ( src/Sqrtx.java ) [ ![ Python] ( https://img.icons8.com/color/35/000000/python.png )] ( python/sqrt.py ) |
28
- | 70 | [ Climbing Stairs] ( https://leetcode.com/problems/climbing-stairs ) | Easy | [ ![ Java] ( https://img.icons8.com/color/40/000000/java-coffee-cup-logo.png )] ( src/ClimbingStairs.java ) |
28
+ | 70 | [ Climbing Stairs] ( https://leetcode.com/problems/climbing-stairs ) | Easy | [ ![ Java] ( https://img.icons8.com/color/40/000000/java-coffee-cup-logo.png )] ( src/ClimbingStairs.java ) [ ![ Python ] ( https://img.icons8.com/color/35/000000/python.png )] ( python/climbing_stairs.py ) |
29
29
| 83 | [ Remove Duplicates from Sorted List] ( https://leetcode.com/problems/remove-duplicates-from-sorted-list ) | Easy | [ ![ Java] ( https://img.icons8.com/color/40/000000/java-coffee-cup-logo.png )] ( src/RemoveDuplicatesFromSortedList.java ) |
30
30
| 88 | [ Merge Sorted Array] ( https://leetcode.com/problems/merge-sorted-array ) | Easy | [ ![ Java] ( https://img.icons8.com/color/40/000000/java-coffee-cup-logo.png )] ( src/MergeSortedArray.java ) |
31
31
| 100 | [ Same Tree] ( https://leetcode.com/problems/same-tree ) | Easy | [ ![ Java] ( https://img.icons8.com/color/40/000000/java-coffee-cup-logo.png )] ( src/SameTree.java ) |
Original file line number Diff line number Diff line change
1
+ def climbStairs (n : int ) -> int :
2
+ prev , current = 1 , 1
3
+ for i in range (n - 1 ):
4
+ prev , current = current , prev + current
5
+ return current
You can’t perform that action at this time.
0 commit comments