├── __init__.py
├── 15-3sum
└── NOTES.md
├── 18-4sum
└── NOTES.md
├── 0050-powx-n
└── NOTES.md
├── 0051-n-queens
└── NOTES.md
├── 0135-candy
└── NOTES.md
├── 0274-h-index
└── NOTES.md
├── 0475-heaters
└── NOTES.md
├── 1-two-sum
├── NOTES.md
└── 1-two-sum.py
├── 100-same-tree
└── NOTES.md
├── 120-triangle
└── NOTES.md
├── 135-candy
└── NOTES.md
├── 146-lru-cache
└── NOTES.md
├── 148-sort-list
└── NOTES.md
├── 155-min-stack
└── NOTES.md
├── 50-powx-n
└── NOTES.md
├── 51-n-queens
└── NOTES.md
├── 542-01-matrix
└── NOTES.md
├── 55-jump-game
└── NOTES.md
├── 78-subsets
└── NOTES.md
├── 90-subsets-ii
└── NOTES.md
├── 0037-sudoku-solver
└── NOTES.md
├── 0045-jump-game-ii
└── NOTES.md
├── 0052-n-queens-ii
└── NOTES.md
├── 0072-edit-distance
└── NOTES.md
├── 0091-decode-ways
└── NOTES.md
├── 0139-word-break
└── NOTES.md
├── 0140-word-break-ii
└── NOTES.md
├── 0146-lru-cache
└── NOTES.md
├── 0198-house-robber
└── NOTES.md
├── 0263-ugly-number
├── NOTES.md
└── 0263-ugly-number.py
├── 0275-h-index-ii
└── NOTES.md
├── 0290-word-pattern
└── NOTES.md
├── 0322-coin-change
└── NOTES.md
├── 0415-add-strings
└── NOTES.md
├── 0456-132-pattern
└── NOTES.md
├── 0493-reverse-pairs
└── NOTES.md
├── 0494-target-sum
└── NOTES.md
├── 0554-brick-wall
└── NOTES.md
├── 0565-array-nesting
└── NOTES.md
├── 0595-big-countries
├── NOTES.md
└── 0595-big-countries.sql
├── 0607-sales-person
├── NOTES.md
└── 0607-sales-person.sql
├── 0608-tree-node
└── NOTES.md
├── 0627-swap-salary
├── NOTES.md
└── 0627-swap-salary.sql
├── 0682-baseball-game
└── NOTES.md
├── 0704-binary-search
└── NOTES.md
├── 0729-my-calendar-i
└── NOTES.md
├── 0752-open-the-lock
└── NOTES.md
├── 0853-car-fleet
└── NOTES.md
├── 0877-stone-game
└── NOTES.md
├── 0912-sort-an-array
└── NOTES.md
├── 101-symmetric-tree
└── NOTES.md
├── 1094-car-pooling
└── NOTES.md
├── 113-path-sum-ii
└── NOTES.md
├── 126-word-ladder-ii
└── NOTES.md
├── 127-word-ladder
└── NOTES.md
├── 1306-jump-game-iii
└── NOTES.md
├── 133-clone-graph
└── NOTES.md
├── 134-gas-station
└── NOTES.md
├── 1345-jump-game-iv
└── NOTES.md
├── 136-single-number
├── NOTES.md
└── 136-single-number.py
├── 139-word-break
└── NOTES.md
├── 140-word-break-ii
└── NOTES.md
├── 143-reorder-list
└── NOTES.md
├── 16-3sum-closest
└── NOTES.md
├── 179-largest-number
└── NOTES.md
├── 1871-jump-game-vii
└── NOTES.md
├── 189-rotate-array
└── NOTES.md
├── 198-house-robber
└── NOTES.md
├── 2-add-two-numbers
└── NOTES.md
├── 202-happy-number
└── NOTES.md
├── 221-maximal-square
└── NOTES.md
├── 228-summary-ranges
└── NOTES.md
├── 242-valid-anagram
└── NOTES.md
├── 2498-frog-jump-ii
└── NOTES.md
├── 258-add-digits
└── NOTES.md
├── 322-coin-change
└── NOTES.md
├── 343-integer-break
└── NOTES.md
├── 344-reverse-string
└── NOTES.md
├── 36-valid-sudoku
└── NOTES.md
├── 37-sudoku-solver
└── NOTES.md
├── 38-count-and-say
└── NOTES.md
├── 39-combination-sum
└── NOTES.md
├── 392-is-subsequence
├── NOTES.md
└── 392-is-subsequence.py
├── 394-decode-string
└── NOTES.md
├── 437-path-sum-iii
└── NOTES.md
├── 45-jump-game-ii
└── NOTES.md
├── 46-permutations
└── NOTES.md
├── 47-permutations-ii
└── NOTES.md
├── 48-rotate-image
└── NOTES.md
├── 493-reverse-pairs
└── NOTES.md
├── 494-target-sum
└── NOTES.md
├── 518-coin-change-2
└── NOTES.md
├── 54-spiral-matrix
└── NOTES.md
├── 56-merge-intervals
└── NOTES.md
├── 57-insert-interval
└── NOTES.md
├── 61-rotate-list
└── NOTES.md
├── 62-unique-paths
├── NOTES.md
└── 62-unique-paths.py
├── 63-unique-paths-ii
└── NOTES.md
├── 677-map-sum-pairs
└── NOTES.md
├── 70-climbing-stairs
└── NOTES.md
├── 71-simplify-path
└── NOTES.md
├── 72-edit-distance
└── NOTES.md
├── 729-my-calendar-i
└── NOTES.md
├── 731-my-calendar-ii
└── NOTES.md
├── 733-flood-fill
└── NOTES.md
├── 75-sort-colors
└── NOTES.md
├── 77-combinations
└── NOTES.md
├── 79-word-search
└── NOTES.md
├── 841-keys-and-rooms
└── NOTES.md
├── 87-scramble-string
└── NOTES.md
├── 877-stone-game
└── NOTES.md
├── 91-decode-ways
└── NOTES.md
├── 912-sort-an-array
└── NOTES.md
├── 0002-add-two-numbers
└── NOTES.md
├── 0012-integer-to-roman
└── NOTES.md
├── 0020-valid-parentheses
└── NOTES.md
├── 0027-remove-element
├── NOTES.md
└── 0027-remove-element.py
├── 0043-multiply-strings
└── NOTES.md
├── 0044-wildcard-matching
└── NOTES.md
├── 0053-maximum-subarray
├── NOTES.md
└── 0053-maximum-subarray.py
├── 0056-merge-intervals
└── NOTES.md
├── 0057-insert-interval
└── NOTES.md
├── 0064-minimum-path-sum
└── NOTES.md
├── 0085-maximal-rectangle
└── NOTES.md
├── 0086-partition-list
└── NOTES.md
├── 0087-scramble-string
└── NOTES.md
├── 0101-symmetric-tree
└── NOTES.md
├── 0137-single-number-ii
└── NOTES.md
├── 0169-majority-element
└── NOTES.md
├── 0182-duplicate-emails
├── NOTES.md
└── 0182-duplicate-emails.sql
├── 0191-number-of-1-bits
├── NOTES.md
└── 0191-number-of-1-bits.py
├── 0200-number-of-islands
└── NOTES.md
├── 0212-word-search-ii
└── NOTES.md
├── 0223-rectangle-area
└── NOTES.md
├── 0224-basic-calculator
└── NOTES.md
├── 0264-ugly-number-ii
└── NOTES.md
├── 0279-perfect-squares
└── NOTES.md
├── 0306-additive-number
└── NOTES.md
├── 0312-burst-balloons
└── NOTES.md
├── 0313-super-ugly-number
└── NOTES.md
├── 0324-wiggle-sort-ii
└── NOTES.md
├── 0337-house-robber-iii
└── NOTES.md
├── 0355-design-twitter
└── NOTES.md
├── 0376-wiggle-subsequence
└── NOTES.md
├── 0377-combination-sum-iv
└── NOTES.md
├── 0384-shuffle-an-array
└── NOTES.md
├── 0391-perfect-rectangle
└── NOTES.md
├── 0392-is-subsequence
└── NOTES.md
├── 0399-evaluate-division
└── NOTES.md
├── 0441-arranging-coins
├── NOTES.md
└── 0441-arranging-coins.py
├── 0443-string-compression
└── NOTES.md
├── 0461-hamming-distance
├── NOTES.md
└── 0461-hamming-distance.py
├── 0474-ones-and-zeroes
└── NOTES.md
├── 0506-relative-ranks
└── NOTES.md
├── 0541-reverse-string-ii
└── NOTES.md
├── 0605-can-place-flowers
└── NOTES.md
├── 0731-my-calendar-ii
└── NOTES.md
├── 0740-delete-and-earn
└── NOTES.md
├── 0743-network-delay-time
└── NOTES.md
├── 0846-hand-of-straights
└── NOTES.md
├── 1035-uncrossed-lines
└── NOTES.md
├── 1046-last-stone-weight
└── NOTES.md
├── 1114-print-in-order
└── NOTES.md
├── 1148-article-views-i
├── NOTES.md
└── 1148-article-views-i.sql
├── 1158-market-analysis-i
├── NOTES.md
└── 1158-market-analysis-i.sql
├── 118-pascals-triangle
└── NOTES.md
├── 119-pascals-triangle-ii
├── NOTES.md
└── 119-pascals-triangle-ii.py
├── 12-integer-to-roman
└── NOTES.md
├── 13-roman-to-integer
└── NOTES.md
├── 130-surrounded-regions
└── NOTES.md
├── 1302-deepest-leaves-sum
└── NOTES.md
├── 1402-reducing-dishes
└── NOTES.md
├── 1407-top-travellers
├── NOTES.md
└── 1407-top-travellers.sql
├── 141-linked-list-cycle
└── NOTES.md
├── 147-insertion-sort-list
└── NOTES.md
├── 169-majority-element
└── NOTES.md
├── 1905-count-sub-islands
└── NOTES.md
├── 1922-count-good-numbers
├── NOTES.md
└── 1922-count-good-numbers.py
├── 20-valid-parentheses
└── NOTES.md
├── 200-number-of-islands
└── NOTES.md
├── 206-reverse-linked-list
└── NOTES.md
├── 207-course-schedule
└── NOTES.md
├── 210-course-schedule-ii
└── NOTES.md
├── 213-house-robber-ii
└── NOTES.md
├── 214-shortest-palindrome
└── NOTES.md
├── 22-generate-parentheses
└── NOTES.md
├── 224-basic-calculator
└── NOTES.md
├── 227-basic-calculator-ii
└── NOTES.md
├── 229-majority-element-ii
└── NOTES.md
├── 23-merge-k-sorted-lists
└── NOTES.md
├── 2611-mice-and-cheese
└── NOTES.md
├── 279-perfect-squares
└── NOTES.md
├── 31-next-permutation
└── NOTES.md
├── 337-house-robber-iii
└── NOTES.md
├── 371-sum-of-two-integers
└── NOTES.md
├── 389-find-the-difference
└── NOTES.md
├── 397-integer-replacement
└── NOTES.md
├── 40-combination-sum-ii
└── NOTES.md
├── 402-remove-k-digits
└── NOTES.md
├── 404-sum-of-left-leaves
└── NOTES.md
├── 409-longest-palindrome
└── NOTES.md
├── 42-trapping-rain-water
└── NOTES.md
├── 43-multiply-strings
└── NOTES.md
├── 44-wildcard-matching
└── NOTES.md
├── 461-hamming-distance
├── NOTES.md
└── 461-hamming-distance.py
├── 474-ones-and-zeroes
└── NOTES.md
├── 525-contiguous-array
└── NOTES.md
├── 53-maximum-subarray
└── NOTES.md
├── 547-number-of-provinces
└── NOTES.md
├── 59-spiral-matrix-ii
└── NOTES.md
├── 60-permutation-sequence
└── NOTES.md
├── 64-minimum-path-sum
└── NOTES.md
├── 695-max-area-of-island
└── NOTES.md
├── 724-find-pivot-index
└── NOTES.md
├── 73-set-matrix-zeroes
└── NOTES.md
├── 735-asteroid-collision
└── NOTES.md
├── 739-daily-temperatures
└── NOTES.md
├── 74-search-a-2d-matrix
└── NOTES.md
├── 740-delete-and-earn
└── NOTES.md
├── 743-network-delay-time
└── NOTES.md
├── 763-partition-labels
└── NOTES.md
├── 767-reorganize-string
└── NOTES.md
├── 781-rabbits-in-forest
└── NOTES.md
├── 785-is-graph-bipartite
└── NOTES.md
├── 814-binary-tree-pruning
└── NOTES.md
├── 836-rectangle-overlap
└── NOTES.md
├── 848-shifting-letters
└── NOTES.md
├── 88-merge-sorted-array
└── NOTES.md
├── 901-online-stock-span
└── NOTES.md
├── 909-snakes-and-ladders
└── NOTES.md
├── 962-maximum-width-ramp
└── NOTES.md
├── 97-interleaving-string
└── NOTES.md
├── 994-rotting-oranges
└── NOTES.md
├── 997-find-the-town-judge
└── NOTES.md
├── Basics-of-Python
├── Modules
│ ├── 01.py
│ ├── dir
│ │ └── myfunction.py
│ ├── rectangle.py
│ ├── triangle.py
│ └── shape.py
├── Practice
│ ├── 34.py
│ ├── 29.py
│ ├── Data-Stractures
│ │ ├── 15_Delete Any Node By Value in Linked List.py
│ │ └── 04_print memory location.py
│ ├── 04.py
│ ├── 28.py
│ ├── 19.py
│ ├── 20_Sets_.py
│ ├── 02.py
│ ├── 27.py
│ ├── 01.py
│ ├── 03.py
│ ├── 06_tuples.py
│ ├── 08_continue_statement.py
│ ├── 09_sum_of_list.py
│ ├── 15_check prime no.py
│ ├── 02_if_else_quick_quiz.py
│ ├── 04_print_list_for.py
│ ├── 10_pr_04.py
│ ├── 05_is_else_optional.py
│ ├── 04_in_and_is.py
│ ├── 18_use of Strip_Function.py
│ ├── 04_try_with_else.py
│ ├── 25_instance_.py
│ ├── 09_05_pr_01.py
│ ├── 33.py
│ ├── 03_logical_and_relational_operators.py
│ ├── 09_08_pr_04.py
│ ├── 14.py
│ ├── 32.py
│ ├── 09_enumerate.py
│ ├── 22properties of sets.py
│ ├── 05_try_except_finally.py
│ ├── 24Dictionary of Hindi to English.py
│ ├── 05_try_except_finally (copy).py
│ ├── 09_07_pr_03.py
│ ├── 08_global.py
│ ├── 09_pr_05.py
│ ├── 06_self.py
│ ├── 09_09_pr_05.py
│ └── 21.py
├── 01.py
├── DSA-problems
│ ├── 01.py
│ └── .vscode
│ │ └── settings.json
├── chapter3 .py
│ ├── Highscore.txt
│ ├── poem.txt
│ ├── append.py
│ ├── write a file.py
│ ├── comment.txt
│ ├── sample.txt
│ ├── with statement.py
│ ├── multiplication table 2 to 20 in different files by for loop
│ │ ├── ZIP_1.png
│ │ └── python.gif
│ ├── table_of_1.txt
│ ├── table_of_2.txt
│ ├── table_of_3.txt
│ ├── table_of_4.txt
│ ├── table_of_5.txt
│ ├── table_of_6.txt
│ ├── table_of_7.txt
│ ├── table_of_8.txt
│ ├── table_of_9.txt
│ ├── log.txt
│ ├── New_File.txt
│ ├── samir.py
│ ├── this.txt
│ ├── table_of_10.txt
│ ├── table_of_11.txt
│ ├── table_of_12.txt
│ ├── table_of_13.txt
│ ├── table_of_14.txt
│ ├── table_of_15.txt
│ ├── table_of_16.txt
│ ├── table_of_17.txt
│ ├── table_of_18.txt
│ ├── table_of_19.txt
│ ├── table_of_20.txt
│ ├── file reading.py
│ └── rewrite_bad_words_from_a_file.py
├── _config.yml
├── LinkedList
│ ├── Doubly Linked List
│ │ └── Circular Linked List .py
│ └── Singly Linked List
│ │ ├── 16_Doubly Linked List.py
│ │ └── 04_print memory location.py
├── 15_Delete Any Node By Value in Linked List.py
├── Table of 5.py
├── Chapter1.py
│ ├── 05_range_function.py
│ ├── Table of 5 (copy)
│ ├── Dictionary Methods
│ ├── 06_for_with_else.py
│ ├── The break statement (copy)
│ ├── 04_print_list_for.py
│ ├── cote to specify strings
│ ├── 07_break_statement.py
│ ├── For loop with else (copy)
│ ├── The continue statement (copy)
│ ├── Py Practice
│ ├── elif clause
│ ├── To take values from the User (copy)
│ ├── To take values from the User (3rd copy)
│ ├── To take values from the User (4th copy)
│ ├── To take values from the User (5th copy)
│ ├── To take values from the User (6th copy)
│ ├── To take values from the User (7th copy)
│ ├── To take values from the User (another copy)
│ ├── Class Attributes
│ ├── converting one data type to another data-type
│ ├── 09_pass_statement.py
│ ├── If else and elif in Python (copy)
│ ├── LexycoGrafic Operators Order (copy)
│ ├── __init__() constructor (copy)
│ ├── If, elif, else. (copy)
│ └── 09_pr_05.py
├── Chapter2.py
│ ├── Sample.txt
│ ├── in_Keyword.py
│ ├── files.py
│ ├── Celcious to ferenhite.py
│ ├── is_Keyword.py
│ ├── 01_import _os.listdir.py
│ ├── Multiplication table in reverse order.py
│ ├── modi.py
│ ├── ends_function.py
│ ├── Length_of_a_Password.py
│ ├── Check if String Contains Substring.py
│ ├── pattern.py
│ ├── inch to cm.py
│ ├── name-greetings-by-for-loop-and-if-else.py
│ ├── 001Conditional_statement_in_python.py
│ ├── Sum of first n natual number using for loop.py
│ ├── Identifing a spam commet from many words.py
│ ├── 02.py
│ └── else_optional.py
├── Git_Push_Commands.py
├── Inheritence+Module
│ ├── dir
│ │ └── myfunction.py
│ ├── rectangle.py
│ ├── shape.py
│ └── triangle.py
├── The break statement.py
├── 07_reduce.py
├── Trick to reverse a string in python.py
├── For loop with else.py
├── Operatos and expressions.py
├── The continue statement.py
├── Queue Data-Stracture
│ ├── Trick to reverse a string in python.py
│ ├── 02.py
│ ├── 06.py
│ ├── 04.py
│ ├── 03.py
│ ├── 07.py
│ └── 05.py
├── Syntax.py
├── 04_print memory location.py
├── To take values from the User.py
├── My First Python Code.py
├── 03_raising_exceptions.py
├── Recursion.py
├── Object_Oriented_Programming
│ ├── 03.py
│ └── 2-D array.py
├── If else and elif in Python.py
├── 03_join.py
├── If elif else.py
├── LexycoGrafic Operators Order.py
├── __init__ constructor.py
├── 05_map.py
└── Static method.py
├── 0014-longest-common-prefix
└── NOTES.md
├── 0022-generate-parentheses
└── NOTES.md
├── 0035-search-insert-position
└── NOTES.md
├── 0093-restore-ip-addresses
└── NOTES.md
├── 0110-balanced-binary-tree
└── NOTES.md
├── 0115-distinct-subsequences
└── NOTES.md
├── 0142-linked-list-cycle-ii
└── NOTES.md
├── 0147-insertion-sort-list
└── NOTES.md
├── 0149-max-points-on-a-line
└── NOTES.md
├── 0176-second-highest-salary
├── NOTES.md
└── 0176-second-highest-salary.sql
├── 0196-delete-duplicate-emails
├── NOTES.md
└── 0196-delete-duplicate-emails.sql
├── 0227-basic-calculator-ii
└── NOTES.md
├── 0229-majority-element-ii
└── NOTES.md
├── 0234-palindrome-linked-list
└── NOTES.md
├── 0239-sliding-window-maximum
└── NOTES.md
├── 0332-reconstruct-itinerary
└── NOTES.md
├── 0347-top-k-frequent-elements
└── NOTES.md
├── 0354-russian-doll-envelopes
└── NOTES.md
├── 0367-valid-perfect-square
└── NOTES.md
├── 0382-linked-list-random-node
└── NOTES.md
├── 0407-trapping-rain-water-ii
└── NOTES.md
├── 0436-find-right-interval
└── NOTES.md
├── 0447-number-of-boomerangs
└── NOTES.md
├── 0473-matchsticks-to-square
└── NOTES.md
├── 0511-game-play-analysis-i
├── NOTES.md
└── 0511-game-play-analysis-i.sql
├── 0523-continuous-subarray-sum
└── NOTES.md
├── 0526-beautiful-arrangement
└── NOTES.md
├── 0567-permutation-in-string
└── NOTES.md
├── 0622-design-circular-queue
└── NOTES.md
├── 0647-palindromic-substrings
└── NOTES.md
├── 0658-find-k-closest-elements
└── NOTES.md
├── 0686-repeated-string-match
└── NOTES.md
├── 0687-longest-univalue-path
└── NOTES.md
├── 0691-stickers-to-spell-word
└── NOTES.md
├── 0778-swim-in-rising-water
└── NOTES.md
├── 0812-largest-triangle-area
└── NOTES.md
├── 0813-largest-sum-of-averages
└── NOTES.md
├── 0875-koko-eating-bananas
└── NOTES.md
├── 0881-boats-to-save-people
└── NOTES.md
├── 0895-maximum-frequency-stack
└── NOTES.md
├── 1014-best-sightseeing-pair
└── NOTES.md
├── 1029-two-city-scheduling
└── NOTES.md
├── 11-container-with-most-water
└── NOTES.md
├── 110-balanced-binary-tree
└── NOTES.md
├── 115-distinct-subsequences
└── NOTES.md
├── 129-sum-root-to-leaf-numbers
└── NOTES.md
├── 131-palindrome-partitioning
└── NOTES.md
├── 1395-count-number-of-teams
└── NOTES.md
├── 14-longest-common-prefix
└── NOTES.md
├── 1405-longest-happy-string
└── NOTES.md
├── 142-linked-list-cycle-ii
└── NOTES.md
├── 1446-consecutive-characters
└── NOTES.md
├── 1472-design-browser-history
└── NOTES.md
├── 1480-running-sum-of-1d-array
└── NOTES.md
├── 152-maximum-product-subarray
└── NOTES.md
├── 165-compare-version-numbers
└── NOTES.md
├── 1667-fix-names-in-a-table
├── NOTES.md
└── 1667-fix-names-in-a-table.sql
├── 1695-maximum-erasure-value
└── NOTES.md
├── 1729-find-followers-count
├── NOTES.md
└── 1729-find-followers-count.sql
├── 1873-calculate-special-bonus
├── NOTES.md
└── 1873-calculate-special-bonus.sql
├── 21-merge-two-sorted-lists
└── NOTES.md
├── 2241-design-an-atm-machine
└── NOTES.md
├── 2296-design-a-text-editor
└── NOTES.md
├── 234-palindrome-linked-list
└── NOTES.md
├── 239-sliding-window-maximum
└── NOTES.md
├── 25-reverse-nodes-in-k-group
└── NOTES.md
├── 2564-substring-xor-queries
└── NOTES.md
├── 316-remove-duplicate-letters
└── NOTES.md
├── 347-top-k-frequent-elements
└── NOTES.md
├── 386-lexicographical-numbers
└── NOTES.md
├── 485-max-consecutive-ones
└── NOTES.md
├── 496-next-greater-element-i
└── NOTES.md
├── 523-continuous-subarray-sum
└── NOTES.md
├── 526-beautiful-arrangement
└── NOTES.md
├── 543-diameter-of-binary-tree
└── NOTES.md
├── 556-next-greater-element-iii
└── NOTES.md
├── 611-valid-triangle-number
└── NOTES.md
├── 617-merge-two-binary-trees
└── NOTES.md
├── 647-palindromic-substrings
└── NOTES.md
├── 652-find-duplicate-subtrees
└── NOTES.md
├── 684-redundant-connection
└── NOTES.md
├── 686-repeated-string-match
└── NOTES.md
├── 687-longest-univalue-path
└── NOTES.md
├── 692-top-k-frequent-words
└── NOTES.md
├── 746-min-cost-climbing-stairs
└── NOTES.md
├── 76-minimum-window-substring
└── NOTES.md
├── 844-backspace-string-compare
└── NOTES.md
├── 881-boats-to-save-people
└── NOTES.md
├── 907-sum-of-subarray-minimums
└── NOTES.md
├── 92-reverse-linked-list-ii
└── NOTES.md
├── 983-minimum-cost-for-tickets
└── NOTES.md
├── 993-cousins-in-binary-tree
└── NOTES.md
├── leetcode-cpp
├── 454-4sum-ii
│ └── NOTES.md
├── 1146-snapshot-array
│ └── NOTES.md
├── 638-shopping-offers
│ └── NOTES.md
├── 1048-longest-string-chain
│ └── NOTES.md
├── 1291-sequential-digits
│ └── NOTES.md
├── 486-predict-the-winner
│ └── NOTES.md
├── 684-redundant-connection
│ └── NOTES.md
├── 1219-path-with-maximum-gold
│ └── NOTES.md
├── 1672-richest-customer-wealth
│ └── NOTES.md
├── 834-sum-of-distances-in-tree
│ └── NOTES.md
├── 121-best-time-to-buy-and-sell-stock
│ └── NOTES.md
├── 1367-linked-list-in-binary-tree
│ └── NOTES.md
├── 438-find-all-anagrams-in-a-string
│ └── NOTES.md
├── 849-maximize-distance-to-closest-person
│ └── NOTES.md
├── 1305-all-elements-in-two-binary-search-trees
│ └── NOTES.md
├── 1297-maximum-number-of-occurrences-of-a-substring
│ └── NOTES.md
├── 1371-find-the-longest-substring-containing-vowels-in-even-counts
│ └── NOTES.md
├── README.md
├── number-of-1-bits
│ └── number-of-1-bits.cpp
├── delete-duplicate-emails
│ └── delete-duplicate-emails.sql
├── power-of-two
│ └── power-of-two.cpp
├── single-number
│ └── single-number.cpp
├── employees-earning-more-than-their-managers
│ └── employees-earning-more-than-their-managers.sql
├── power-of-four
│ └── power-of-four.cpp
├── department-highest-salary
│ └── department-highest-salary.sql
└── reverse-bits
│ └── reverse-bits.cpp
├── 0004-median-of-two-sorted-arrays
└── NOTES.md
├── 0010-regular-expression-matching
└── NOTES.md
├── 0124-binary-tree-maximum-path-sum
└── NOTES.md
├── 0129-sum-root-to-leaf-numbers
└── NOTES.md
├── 0151-reverse-words-in-a-string
└── NOTES.md
├── 0171-excel-sheet-column-number
└── NOTES.md
├── 0199-binary-tree-right-side-view
└── NOTES.md
├── 0201-bitwise-and-of-numbers-range
└── NOTES.md
├── 0208-implement-trie-prefix-tree
└── NOTES.md
├── 0222-count-complete-tree-nodes
└── NOTES.md
├── 0238-product-of-array-except-self
└── NOTES.md
├── 0368-largest-divisible-subset
└── NOTES.md
├── 0374-guess-number-higher-or-lower
└── NOTES.md
├── 0380-insert-delete-getrandom-o1
└── NOTES.md
├── 0416-partition-equal-subset-sum
└── NOTES.md
├── 0513-find-bottom-left-tree-value
└── NOTES.md
├── 0535-encode-and-decode-tinyurl
└── NOTES.md
├── 0646-maximum-length-of-pair-chain
└── NOTES.md
├── 0667-beautiful-arrangement-ii
└── NOTES.md
├── 0669-trim-a-binary-search-tree
└── NOTES.md
├── 0678-valid-parenthesis-string
└── NOTES.md
├── 0713-subarray-product-less-than-k
└── NOTES.md
├── 0790-domino-and-tromino-tiling
└── NOTES.md
├── 0802-find-eventual-safe-states
└── NOTES.md
├── 0823-binary-trees-with-factors
└── NOTES.md
├── 0876-middle-of-the-linked-list
└── NOTES.md
├── 0974-subarray-sums-divisible-by-k
└── NOTES.md
├── 0981-time-based-key-value-store
└── NOTES.md
├── 0983-minimum-cost-for-tickets
└── NOTES.md
├── 10-regular-expression-matching
└── NOTES.md
├── 1004-max-consecutive-ones-iii
└── NOTES.md
├── 104-maximum-depth-of-binary-tree
└── NOTES.md
├── 1079-letter-tile-possibilities
└── NOTES.md
├── 1106-parsing-a-boolean-expression
└── NOTES.md
├── 1143-longest-common-subsequence
└── NOTES.md
├── 1162-as-far-from-land-as-possible
└── NOTES.md
├── 1189-maximum-number-of-balloons
├── NOTES.md
└── 1189-maximum-number-of-balloons.py
├── 1200-minimum-absolute-difference
└── NOTES.md
├── 1207-unique-number-of-occurrences
└── NOTES.md
├── 1220-count-vowels-permutation
└── NOTES.md
├── 124-binary-tree-maximum-path-sum
└── NOTES.md
├── 1268-search-suggestions-system
└── NOTES.md
├── 128-longest-consecutive-sequence
└── NOTES.md
├── 1288-remove-covered-intervals
└── NOTES.md
├── 1367-linked-list-in-binary-tree
└── NOTES.md
├── 138-copy-list-with-random-pointer
└── NOTES.md
├── 1382-balance-a-binary-search-tree
└── NOTES.md
├── 151-reverse-words-in-a-string
└── NOTES.md
├── 1539-kth-missing-positive-number
└── NOTES.md
├── 1631-path-with-minimum-effort
└── NOTES.md
├── 1693-daily-leads-and-partners
├── NOTES.md
└── 1693-daily-leads-and-partners.sql
├── 1710-maximum-units-on-a-truck
└── NOTES.md
├── 172-factorial-trailing-zeroes
├── NOTES.md
└── 172-factorial-trailing-zeroes.py
├── 173-binary-search-tree-iterator
└── NOTES.md
├── 1795-rearrange-products-table
└── NOTES.md
├── 1845-seat-reservation-manager
└── NOTES.md
├── 1882-process-tasks-using-servers
└── NOTES.md
├── 1890-the-latest-login-in-2020
├── NOTES.md
└── 1890-the-latest-login-in-2020.sql
├── 1971-find-if-path-exists-in-graph
└── NOTES.md
├── 1980-find-unique-binary-string
└── NOTES.md
├── 199-binary-tree-right-side-view
└── NOTES.md
├── 208-implement-trie-prefix-tree
└── NOTES.md
├── 209-minimum-size-subarray-sum
└── NOTES.md
├── 222-count-complete-tree-nodes
└── NOTES.md
├── 225-implement-stack-using-queues
└── NOTES.md
├── 230-kth-smallest-element-in-a-bst
└── NOTES.md
├── 2304-minimum-path-cost-in-a-grid
└── NOTES.md
├── 232-implement-queue-using-stacks
└── NOTES.md
├── 2360-longest-cycle-in-a-graph
└── NOTES.md
├── 237-delete-node-in-a-linked-list
└── NOTES.md
├── 238-product-of-array-except-self
└── NOTES.md
├── 2409-count-days-spent-together
└── NOTES.md
├── 287-find-the-duplicate-number
└── NOTES.md
├── 295-find-median-from-data-stream
└── NOTES.md
├── 33-search-in-rotated-sorted-array
└── NOTES.md
├── 349-intersection-of-two-arrays
└── NOTES.md
├── 4-median-of-two-sorted-arrays
└── NOTES.md
├── 416-partition-equal-subset-sum
└── NOTES.md
├── 435-non-overlapping-intervals
└── NOTES.md
├── 5-longest-palindromic-substring
└── NOTES.md
├── 535-encode-and-decode-tinyurl
└── NOTES.md
├── 538-convert-bst-to-greater-tree
└── NOTES.md
├── 589-n-ary-tree-preorder-traversal
└── NOTES.md
├── 646-maximum-length-of-pair-chain
└── NOTES.md
├── 653-two-sum-iv-input-is-a-bst
└── NOTES.md
├── 662-maximum-width-of-binary-tree
└── NOTES.md
├── 713-subarray-product-less-than-k
└── NOTES.md
├── 720-longest-word-in-dictionary
└── NOTES.md
├── 769-max-chunks-to-make-sorted
└── NOTES.md
├── 823-binary-trees-with-factors
└── NOTES.md
├── 84-largest-rectangle-in-histogram
└── NOTES.md
├── 876-middle-of-the-linked-list
└── NOTES.md
├── 94-binary-tree-inorder-traversal
└── NOTES.md
├── 96-unique-binary-search-trees
└── NOTES.md
├── 973-k-closest-points-to-origin
└── NOTES.md
├── 974-subarray-sums-divisible-by-k
└── NOTES.md
├── 98-validate-binary-search-tree
└── NOTES.md
├── 0005-longest-palindromic-substring
└── NOTES.md
├── 0094-binary-tree-inorder-traversal
└── NOTES.md
├── 0102-binary-tree-level-order-traversal
└── NOTES.md
├── 0144-binary-tree-preorder-traversal
└── NOTES.md
├── 0145-binary-tree-postorder-traversal
└── NOTES.md
├── 0166-fraction-to-recurring-decimal
└── NOTES.md
├── 0300-longest-increasing-subsequence
└── NOTES.md
├── 0318-maximum-product-of-word-lengths
└── NOTES.md
├── 0357-count-numbers-with-unique-digits
└── NOTES.md
├── 0373-find-k-pairs-with-smallest-sums
└── NOTES.md
├── 0375-guess-number-higher-or-lower-ii
└── NOTES.md
├── 0406-queue-reconstruction-by-height
└── NOTES.md
├── 0606-construct-string-from-binary-tree
└── NOTES.md
├── 0688-knight-probability-in-chessboard
└── NOTES.md
├── 0698-partition-to-k-equal-sum-subsets
└── NOTES.md
├── 0787-cheapest-flights-within-k-stops
└── NOTES.md
├── 0797-all-paths-from-source-to-target
└── NOTES.md
├── 0894-all-possible-full-binary-trees
└── NOTES.md
├── 0953-verifying-an-alien-dictionary
└── NOTES.md
├── 0979-distribute-coins-in-binary-tree
└── NOTES.md
├── 102-binary-tree-level-order-traversal
└── NOTES.md
├── 1027-longest-arithmetic-subsequence
└── NOTES.md
├── 1092-shortest-common-supersequence
└── NOTES.md
├── 114-flatten-binary-tree-to-linked-list
└── NOTES.md
├── 121-best-time-to-buy-and-sell-stock
├── NOTES.md
└── 121-best-time-to-buy-and-sell-stock.py
├── 122-best-time-to-buy-and-sell-stock-ii
└── NOTES.md
├── 1235-maximum-profit-in-job-scheduling
└── NOTES.md
├── 1373-maximum-sum-bst-in-binary-tree
└── NOTES.md
├── 1383-maximum-performance-of-a-team
└── NOTES.md
├── 144-binary-tree-preorder-traversal
└── NOTES.md
├── 1444-number-of-ways-of-cutting-a-pizza
└── NOTES.md
├── 1448-count-good-nodes-in-binary-tree
└── NOTES.md
├── 1530-number-of-good-leaf-nodes-pairs
└── NOTES.md
├── 1545-find-kth-bit-in-nth-binary-string
└── NOTES.md
├── 1584-min-cost-to-connect-all-points
└── NOTES.md
├── 160-intersection-of-two-linked-lists
└── NOTES.md
├── 1757-recyclable-and-low-fat-products
├── NOTES.md
└── 1757-recyclable-and-low-fat-products.sql
├── 188-best-time-to-buy-and-sell-stock-iv
└── NOTES.md
├── 1884-egg-drop-with-2-eggs-and-n-floors
└── NOTES.md
├── 19-remove-nth-node-from-end-of-list
└── NOTES.md
├── 2024-maximize-the-confusion-of-an-exam
└── NOTES.md
├── 215-kth-largest-element-in-an-array
└── NOTES.md
├── 2187-minimum-time-to-complete-trips
└── NOTES.md
├── 2301-match-substring-after-replacement
└── NOTES.md
├── 2321-maximum-score-of-spliced-array
└── NOTES.md
├── 2348-number-of-zero-filled-subarrays
└── NOTES.md
├── 241-different-ways-to-add-parentheses
└── NOTES.md
├── 2444-count-subarrays-with-fixed-bounds
└── NOTES.md
├── 2448-minimum-cost-to-make-array-equal
└── NOTES.md
├── 2488-count-subarrays-with-median-k
└── NOTES.md
├── 2597-the-number-of-beautiful-subsets
└── NOTES.md
├── 26-remove-duplicates-from-sorted-array
└── NOTES.md
├── 300-longest-increasing-subsequence
└── NOTES.md
├── 387-first-unique-character-in-a-string
└── NOTES.md
├── 406-queue-reconstruction-by-height
└── NOTES.md
├── 516-longest-palindromic-subsequence
└── NOTES.md
├── 540-single-element-in-a-sorted-array
└── NOTES.md
├── 583-delete-operation-for-two-strings
└── NOTES.md
├── 628-maximum-product-of-three-numbers
└── NOTES.md
├── 688-knight-probability-in-chessboard
└── NOTES.md
├── 700-search-in-a-binary-search-tree
└── NOTES.md
├── 703-kth-largest-element-in-a-stream
└── NOTES.md
├── 787-cheapest-flights-within-k-stops
└── NOTES.md
├── 797-all-paths-from-source-to-target
└── NOTES.md
├── 0017-letter-combinations-of-a-phone-number
└── NOTES.md
├── 0114-flatten-binary-tree-to-linked-list
└── NOTES.md
├── 0122-best-time-to-buy-and-sell-stock-ii
└── NOTES.md
├── 0329-longest-increasing-path-in-a-matrix
└── NOTES.md
├── 0363-max-sum-of-rectangle-no-larger-than-k
└── NOTES.md
├── 0467-unique-substrings-in-wraparound-string
└── NOTES.md
├── 0530-minimum-absolute-difference-in-bst
└── NOTES.md
├── 0958-check-completeness-of-a-binary-tree
└── NOTES.md
├── 1038-binary-search-tree-to-greater-sum-tree
└── NOTES.md
├── 1071-greatest-common-divisor-of-strings
└── NOTES.md
├── 1130-minimum-cost-tree-from-leaf-values
└── NOTES.md
├── 1208-get-equal-substrings-within-budget
└── NOTES.md
├── 1221-split-a-string-in-balanced-strings
└── NOTES.md
├── 123-best-time-to-buy-and-sell-stock-iii
└── NOTES.md
├── 1673-find-the-most-competitive-subsequence
└── NOTES.md
├── 17-letter-combinations-of-a-phone-number
└── NOTES.md
├── 1741-find-total-time-spent-by-each-employee
└── NOTES.md
├── 1844-replace-all-digits-with-characters
├── NOTES.md
└── 1844-replace-all-digits-with-characters.py
├── 1851-minimum-interval-to-include-each-query
└── NOTES.md
├── 1898-maximum-number-of-removable-characters
└── NOTES.md
├── 1911-maximum-alternating-subsequence-sum
└── NOTES.md
├── 1921-eliminate-maximum-number-of-monsters
└── NOTES.md
├── 1965-employees-with-missing-information
└── NOTES.md
├── 2300-successful-pairs-of-spells-and-potions
└── NOTES.md
├── 2302-count-subarrays-with-score-less-than-k
└── NOTES.md
├── 2320-count-number-of-ways-to-place-houses
└── NOTES.md
├── 236-lowest-common-ancestor-of-a-binary-tree
└── NOTES.md
├── 2423-remove-letter-to-equalize-frequency
└── NOTES.md
├── 2452-words-within-two-edits-of-dictionary
└── NOTES.md
├── 2565-subsequence-with-the-minimum-score
└── NOTES.md
├── 297-serialize-and-deserialize-binary-tree
└── NOTES.md
├── 329-longest-increasing-path-in-a-matrix
└── NOTES.md
├── 378-kth-smallest-element-in-a-sorted-matrix
└── NOTES.md
├── 421-maximum-xor-of-two-numbers-in-an-array
└── NOTES.md
├── 430-flatten-a-multilevel-doubly-linked-list
└── NOTES.md
├── 581-shortest-unsorted-continuous-subarray
└── NOTES.md
├── 80-remove-duplicates-from-sorted-array-ii
└── NOTES.md
├── 921-minimum-add-to-make-parentheses-valid
└── NOTES.md
├── 958-check-completeness-of-a-binary-tree
└── NOTES.md
├── 0103-binary-tree-zigzag-level-order-traversal
└── NOTES.md
├── 0109-convert-sorted-list-to-binary-search-tree
└── NOTES.md
├── 0211-design-add-and-search-words-data-structure
└── NOTES.md
├── 0236-lowest-common-ancestor-of-a-binary-tree
└── NOTES.md
├── 0378-kth-smallest-element-in-a-sorted-matrix
└── NOTES.md
├── 0424-longest-repeating-character-replacement
└── NOTES.md
├── 0452-minimum-number-of-arrows-to-burst-balloons
└── NOTES.md
├── 0673-number-of-longest-increasing-subsequence
└── NOTES.md
├── 0689-maximum-sum-of-3-non-overlapping-subarrays
└── NOTES.md
├── 0987-vertical-order-traversal-of-a-binary-tree
└── NOTES.md
├── 1005-maximize-sum-of-array-after-k-negations
└── NOTES.md
├── 1011-capacity-to-ship-packages-within-d-days
└── NOTES.md
├── 103-binary-tree-zigzag-level-order-traversal
└── NOTES.md
├── 108-convert-sorted-array-to-binary-search-tree
└── NOTES.md
├── 109-convert-sorted-list-to-binary-search-tree
└── NOTES.md
├── 116-populating-next-right-pointers-in-each-node
└── NOTES.md
├── 1209-remove-all-adjacent-duplicates-in-string-ii
└── NOTES.md
├── 1318-minimum-flips-to-make-a-or-b-equal-to-c
└── NOTES.md
├── 1342-number-of-steps-to-reduce-a-number-to-zero
└── NOTES.md
├── 1423-maximum-points-you-can-obtain-from-cards
└── NOTES.md
├── 1605-find-valid-matrix-given-row-and-column-sums
└── NOTES.md
├── 1614-maximum-nesting-depth-of-the-parentheses
└── NOTES.md
├── 1855-maximum-distance-between-a-pair-of-values
└── NOTES.md
├── 1930-unique-length-3-palindromic-subsequences
└── NOTES.md
├── 2091-removing-minimum-and-maximum-from-array
└── NOTES.md
├── 211-design-add-and-search-words-data-structure
└── NOTES.md
├── 2271-maximum-white-tiles-covered-by-a-carpet
└── NOTES.md
├── 2411-smallest-subarrays-with-maximum-bitwise-or
└── NOTES.md
├── 2477-minimum-fuel-cost-to-report-to-the-capital
└── NOTES.md
├── 2492-minimum-score-of-a-path-between-two-cities
└── NOTES.md
├── 2508-add-edges-to-make-degrees-of-all-nodes-even
└── NOTES.md
├── 3-longest-substring-without-repeating-characters
└── NOTES.md
├── 448-find-all-numbers-disappeared-in-an-array
└── NOTES.md
├── 452-minimum-number-of-arrows-to-burst-balloons
└── NOTES.md
├── 674-longest-continuous-increasing-subsequence
└── NOTES.md
├── 801-minimum-swaps-to-make-sequences-increasing
└── NOTES.md
├── 987-vertical-order-traversal-of-a-binary-tree
└── NOTES.md
├── 0003-longest-substring-without-repeating-characters
└── NOTES.md
├── 0117-populating-next-right-pointers-in-each-node-ii
└── NOTES.md
├── 0331-verify-preorder-serialization-of-a-binary-tree
└── NOTES.md
├── 0586-customer-placing-the-largest-number-of-orders
├── NOTES.md
└── 0586-customer-placing-the-largest-number-of-orders.sql
├── 1296-divide-array-in-sets-of-k-consecutive-numbers
└── NOTES.md
├── 1309-decrypt-string-from-alphabet-to-integer-mapping
└── NOTES.md
├── 1319-number-of-operations-to-make-network-connected
└── NOTES.md
├── 1685-sum-of-absolute-differences-in-a-sorted-array
└── NOTES.md
├── 2001-number-of-pairs-of-interchangeable-rectangles
└── NOTES.md
├── 2006-count-number-of-pairs-with-absolute-difference-k
└── NOTES.md
├── 235-lowest-common-ancestor-of-a-binary-search-tree
└── NOTES.md
├── 2546-apply-bitwise-operations-to-make-strings-equal
├── NOTES.md
└── 2546-apply-bitwise-operations-to-make-strings-equal.py
├── 309-best-time-to-buy-and-sell-stock-with-cooldown
└── NOTES.md
├── 0028-find-the-index-of-the-first-occurrence-in-a-string
└── NOTES.md
├── 0714-best-time-to-buy-and-sell-stock-with-transaction-fee
└── NOTES.md
├── 1008-construct-binary-search-tree-from-preorder-traversal
└── NOTES.md
├── 1312-minimum-insertion-steps-to-make-a-string-palindrome
└── NOTES.md
├── 1347-minimum-number-of-steps-to-make-two-strings-anagram
└── NOTES.md
├── 1461-check-if-a-string-contains-all-binary-codes-of-size-k
└── NOTES.md
├── 1493-longest-subarray-of-1s-after-deleting-one-element
└── NOTES.md
├── 1849-splitting-a-string-into-descending-consecutive-values
└── NOTES.md
├── 1963-minimum-number-of-swaps-to-make-the-string-balanced
└── NOTES.md
├── 1968-array-with-elements-not-equal-to-average-of-neighbors
└── NOTES.md
├── 1974-minimum-time-to-type-word-using-special-typewriter
└── NOTES.md
├── 2449-minimum-number-of-operations-to-make-arrays-similar
└── NOTES.md
├── 714-best-time-to-buy-and-sell-stock-with-transaction-fee
└── NOTES.md
├── ads.txt
├── 0105-construct-binary-tree-from-preorder-and-inorder-traversal
└── NOTES.md
├── 0106-construct-binary-tree-from-inorder-and-postorder-traversal
└── NOTES.md
├── 105-construct-binary-tree-from-preorder-and-inorder-traversal
└── NOTES.md
├── 106-construct-binary-tree-from-inorder-and-postorder-traversal
└── NOTES.md
├── 1466-reorder-routes-to-make-all-paths-lead-to-the-city-zero
└── NOTES.md
├── 1581-customer-who-visited-but-did-not-make-any-transactions
└── NOTES.md
├── 1866-number-of-ways-to-rearrange-sticks-with-k-sticks-visible
└── NOTES.md
├── 889-construct-binary-tree-from-preorder-and-postorder-traversal
└── NOTES.md
├── 0889-construct-binary-tree-from-preorder-and-postorder-traversal
└── NOTES.md
├── 1239-maximum-length-of-a-concatenated-string-with-unique-characters
└── NOTES.md
├── 1888-minimum-number-of-flips-to-make-the-binary-string-alternating
└── NOTES.md
├── 1465-maximum-area-of-a-piece-of-cake-after-horizontal-and-vertical-cuts
└── NOTES.md
├── 1509-minimum-difference-between-largest-and-smallest-value-in-three-moves
└── NOTES.md
├── 1334-find-the-city-with-the-smallest-number-of-neighbors-at-a-threshold-distance
└── NOTES.md
├── BingSiteAuth.xml
├── problems
├── to_lower_case
│ └── solution.py
├── partitioning_into_minimum_number_of_deci-binary_numbers
│ └── solution.py
├── check_if_the_sentence_is_pangram
│ └── solution.py
├── count_negative_numbers_in_a_sorted_matrix
│ └── solution.py
├── find_the_index_of_the_first_occurrence_in_a_string
│ └── solution.py
├── missing_number
│ └── solution.py
├── gray_code
│ └── solution.py
├── single_number
│ └── solution.py
├── lucky_numbers_in_a_matrix
│ └── solution.py
├── maximum_product_difference_between_two_pairs
│ └── solution.py
├── power_of_four
│ └── solution.py
├── power_of_three
│ └── solution.py
├── valid_anagram
│ └── solution.py
├── counting_bits
│ └── solution.py
├── contains_duplicate
│ └── solution.py
├── defanging_an_ip_address
│ └── solution.py
├── rotate_array
│ └── solution.py
├── factorial_trailing_zeroes
│ └── solution.py
├── fair_candy_swap
│ └── solution.py
├── power_of_two
│ └── solution.py
├── shuffle_string
│ └── solution.py
├── fibonacci_number
│ └── solution.py
├── maximum_product_of_two_elements_in_an_array
│ └── solution.py
├── richest_customer_wealth
│ └── solution.py
├── find_numbers_with_even_number_of_digits
│ └── solution.py
├── minimum_moves_to_equal_array_elements_ii
│ └── solution.py
├── squares_of_a_sorted_array
│ └── solution.py
├── truncate_sentence
│ └── solution.py
├── array_partition
│ └── solution.py
├── find_the_highest_altitude
│ └── solution.py
├── egg_drop_with_2_eggs_and_n_floors
│ └── solution.py
├── kth_smallest_element_in_a_sorted_matrix
│ └── solution.py
├── reverse_string
│ └── solution.py
├── sort_colors
│ └── solution.py
├── sum_of_digits_in_base_k
│ └── solution.py
├── shuffle_the_array
│ └── solution.py
├── valid_palindrome
│ └── solution.py
├── best_time_to_buy_and_sell_stock_ii
│ └── solution.py
├── goal_parser_interpretation
│ └── solution.py
├── running_sum_of_1d_array
│ └── solution.py
└── unique_paths
│ └── solution.py
├── .gitmodules
├── 1527-patients-with-a-condition
└── 1527-patients-with-a-condition.sql
├── assets
└── long-banner-breck-img-readme-unnamed.png
├── 162-find-peak-element
└── NOTES.md
├── 0584-find-customer-referee
└── 0584-find-customer-referee.sql
├── 292_Nim_Game.py
├── 0197-rising-temperature
├── 0197-rising-temperature.sql
└── NOTES.md
├── 1323_Maximum_69_Number.py
├── 344_Reverse_String.py
├── 0136-single-number
└── 0136-single-number.py
├── 0175-combine-two-tables
└── 0175-combine-two-tables.sql
├── 1393-capital-gain-loss
└── 1393-capital-gain-loss.sql
├── 0183-customers-who-never-order
└── 0183-customers-who-never-order.sql
├── 0190-reverse-bits
└── 0190-reverse-bits.py
├── 461_Hamming_Distance.py
├── 557_Reverse_Words_in_a_String_III.py
├── 0070-climbing-stairs
└── 0070-climbing-stairs.py
├── 1141-user-activity-for-the-past-30-days-i
└── 1141-user-activity-for-the-past-30-days-i.sql
├── 168_Excel_Sheet_Column_Title.py
├── 1084-sales-analysis-iii
└── 1084-sales-analysis-iii.sql
├── 0189-rotate-array
└── 0189-rotate-array.py
├── 1587-bank-account-summary-ii
└── 1587-bank-account-summary-ii.sql
├── 1050-actors-and-directors-who-cooperated-at-least-three-times
└── 1050-actors-and-directors-who-cooperated-at-least-three-times.sql
├── 0462-minimum-moves-to-equal-array-elements-ii
└── 0462-minimum-moves-to-equal-array-elements-ii.py
├── 349_Intersection_of_Two_Arrays.py
├── 771-jewels-and-stones
└── 771-jewels-and-stones.py
├── 0746-min-cost-climbing-stairs
└── 0746-min-cost-climbing-stairs.py
├── 1484-group-sold-products-by-the-date
└── 1484-group-sold-products-by-the-date.sql
├── 1985-find-the-kth-largest-integer-in-the-array
└── 1985-find-the-kth-largest-integer-in-the-array.py
├── 137-single-number-ii
└── 137-single-number-ii.py
├── 231_Power_of_Two.py
├── 961-n-repeated-element-in-size-2n-array
└── 961-n-repeated-element-in-size-2n-array.py
├── 0096-unique-binary-search-trees
└── 0096-unique-binary-search-trees.py
├── 0121-best-time-to-buy-and-sell-stock
└── 0121-best-time-to-buy-and-sell-stock.py
├── 258_Add_Digits.py
├── 0001-two-sum
└── 0001-two-sum.py
└── 179_Largest_Number.py
/__init__.py:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/15-3sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/18-4sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0050-powx-n/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0051-n-queens/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0135-candy/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0274-h-index/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0475-heaters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1-two-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/100-same-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/120-triangle/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/135-candy/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/146-lru-cache/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/148-sort-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/155-min-stack/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/50-powx-n/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/51-n-queens/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/542-01-matrix/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/55-jump-game/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/78-subsets/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/90-subsets-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0037-sudoku-solver/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0045-jump-game-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0052-n-queens-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0072-edit-distance/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0091-decode-ways/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0139-word-break/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0140-word-break-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0146-lru-cache/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0198-house-robber/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0263-ugly-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0275-h-index-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0290-word-pattern/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0322-coin-change/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0415-add-strings/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0456-132-pattern/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0493-reverse-pairs/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0494-target-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0554-brick-wall/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0565-array-nesting/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0595-big-countries/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0607-sales-person/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0608-tree-node/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0627-swap-salary/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0682-baseball-game/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0704-binary-search/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0729-my-calendar-i/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0752-open-the-lock/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0853-car-fleet/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0877-stone-game/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0912-sort-an-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/101-symmetric-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1094-car-pooling/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/113-path-sum-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/126-word-ladder-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/127-word-ladder/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1306-jump-game-iii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/133-clone-graph/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/134-gas-station/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1345-jump-game-iv/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/136-single-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/139-word-break/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/140-word-break-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/143-reorder-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/16-3sum-closest/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/179-largest-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1871-jump-game-vii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/189-rotate-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/198-house-robber/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2-add-two-numbers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/202-happy-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/221-maximal-square/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/228-summary-ranges/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/242-valid-anagram/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2498-frog-jump-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/258-add-digits/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/322-coin-change/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/343-integer-break/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/344-reverse-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/36-valid-sudoku/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/37-sudoku-solver/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/38-count-and-say/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/39-combination-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/392-is-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/394-decode-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/437-path-sum-iii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/45-jump-game-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/46-permutations/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/47-permutations-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/48-rotate-image/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/493-reverse-pairs/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/494-target-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/518-coin-change-2/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/54-spiral-matrix/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/56-merge-intervals/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/57-insert-interval/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/61-rotate-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/62-unique-paths/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/63-unique-paths-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/677-map-sum-pairs/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/70-climbing-stairs/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/71-simplify-path/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/72-edit-distance/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/729-my-calendar-i/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/731-my-calendar-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/733-flood-fill/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/75-sort-colors/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/77-combinations/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/79-word-search/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/841-keys-and-rooms/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/87-scramble-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/877-stone-game/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/91-decode-ways/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/912-sort-an-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0002-add-two-numbers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0012-integer-to-roman/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0020-valid-parentheses/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0027-remove-element/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0043-multiply-strings/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0044-wildcard-matching/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0053-maximum-subarray/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0056-merge-intervals/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0057-insert-interval/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0064-minimum-path-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0085-maximal-rectangle/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0086-partition-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0087-scramble-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0101-symmetric-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0137-single-number-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0169-majority-element/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0182-duplicate-emails/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0191-number-of-1-bits/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0200-number-of-islands/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0212-word-search-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0223-rectangle-area/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0224-basic-calculator/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0264-ugly-number-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0279-perfect-squares/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0306-additive-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0312-burst-balloons/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0313-super-ugly-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0324-wiggle-sort-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0337-house-robber-iii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0355-design-twitter/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0376-wiggle-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0377-combination-sum-iv/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0384-shuffle-an-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0391-perfect-rectangle/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0392-is-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0399-evaluate-division/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0441-arranging-coins/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0443-string-compression/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0461-hamming-distance/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0474-ones-and-zeroes/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0506-relative-ranks/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0541-reverse-string-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0605-can-place-flowers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0731-my-calendar-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0740-delete-and-earn/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0743-network-delay-time/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0846-hand-of-straights/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1035-uncrossed-lines/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1046-last-stone-weight/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1114-print-in-order/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1148-article-views-i/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1158-market-analysis-i/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/118-pascals-triangle/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/119-pascals-triangle-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/12-integer-to-roman/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/13-roman-to-integer/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/130-surrounded-regions/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1302-deepest-leaves-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1402-reducing-dishes/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1407-top-travellers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/141-linked-list-cycle/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/147-insertion-sort-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/169-majority-element/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1905-count-sub-islands/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1922-count-good-numbers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/20-valid-parentheses/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/200-number-of-islands/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/206-reverse-linked-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/207-course-schedule/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/210-course-schedule-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/213-house-robber-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/214-shortest-palindrome/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/22-generate-parentheses/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/224-basic-calculator/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/227-basic-calculator-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/229-majority-element-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/23-merge-k-sorted-lists/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2611-mice-and-cheese/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/279-perfect-squares/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/31-next-permutation/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/337-house-robber-iii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/371-sum-of-two-integers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/389-find-the-difference/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/397-integer-replacement/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/40-combination-sum-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/402-remove-k-digits/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/404-sum-of-left-leaves/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/409-longest-palindrome/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/42-trapping-rain-water/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/43-multiply-strings/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/44-wildcard-matching/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/461-hamming-distance/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/474-ones-and-zeroes/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/525-contiguous-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/53-maximum-subarray/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/547-number-of-provinces/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/59-spiral-matrix-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/60-permutation-sequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/64-minimum-path-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/695-max-area-of-island/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/724-find-pivot-index/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/73-set-matrix-zeroes/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/735-asteroid-collision/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/739-daily-temperatures/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/74-search-a-2d-matrix/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/740-delete-and-earn/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/743-network-delay-time/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/763-partition-labels/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/767-reorganize-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/781-rabbits-in-forest/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/785-is-graph-bipartite/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/814-binary-tree-pruning/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/836-rectangle-overlap/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/848-shifting-letters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/88-merge-sorted-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/901-online-stock-span/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/909-snakes-and-ladders/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/962-maximum-width-ramp/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/97-interleaving-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/994-rotting-oranges/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/997-find-the-town-judge/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/Modules/01.py:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/34.py:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0014-longest-common-prefix/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0022-generate-parentheses/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0035-search-insert-position/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0093-restore-ip-addresses/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0110-balanced-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0115-distinct-subsequences/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0142-linked-list-cycle-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0147-insertion-sort-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0149-max-points-on-a-line/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0176-second-highest-salary/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0196-delete-duplicate-emails/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0227-basic-calculator-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0229-majority-element-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0234-palindrome-linked-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0239-sliding-window-maximum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0332-reconstruct-itinerary/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0347-top-k-frequent-elements/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0354-russian-doll-envelopes/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0367-valid-perfect-square/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0382-linked-list-random-node/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0407-trapping-rain-water-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0436-find-right-interval/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0447-number-of-boomerangs/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0473-matchsticks-to-square/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0511-game-play-analysis-i/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0523-continuous-subarray-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0526-beautiful-arrangement/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0567-permutation-in-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0622-design-circular-queue/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0647-palindromic-substrings/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0658-find-k-closest-elements/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0686-repeated-string-match/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0687-longest-univalue-path/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0691-stickers-to-spell-word/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0778-swim-in-rising-water/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0812-largest-triangle-area/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0813-largest-sum-of-averages/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0875-koko-eating-bananas/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0881-boats-to-save-people/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0895-maximum-frequency-stack/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1014-best-sightseeing-pair/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1029-two-city-scheduling/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/11-container-with-most-water/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/110-balanced-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/115-distinct-subsequences/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/129-sum-root-to-leaf-numbers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/131-palindrome-partitioning/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1395-count-number-of-teams/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/14-longest-common-prefix/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1405-longest-happy-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/142-linked-list-cycle-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1446-consecutive-characters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1472-design-browser-history/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1480-running-sum-of-1d-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/152-maximum-product-subarray/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/165-compare-version-numbers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1667-fix-names-in-a-table/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1695-maximum-erasure-value/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1729-find-followers-count/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1873-calculate-special-bonus/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/21-merge-two-sorted-lists/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2241-design-an-atm-machine/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2296-design-a-text-editor/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/234-palindrome-linked-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/239-sliding-window-maximum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/25-reverse-nodes-in-k-group/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2564-substring-xor-queries/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/316-remove-duplicate-letters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/347-top-k-frequent-elements/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/386-lexicographical-numbers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/485-max-consecutive-ones/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/496-next-greater-element-i/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/523-continuous-subarray-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/526-beautiful-arrangement/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/543-diameter-of-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/556-next-greater-element-iii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/611-valid-triangle-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/617-merge-two-binary-trees/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/647-palindromic-substrings/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/652-find-duplicate-subtrees/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/684-redundant-connection/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/686-repeated-string-match/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/687-longest-univalue-path/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/692-top-k-frequent-words/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/746-min-cost-climbing-stairs/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/76-minimum-window-substring/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/844-backspace-string-compare/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/881-boats-to-save-people/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/907-sum-of-subarray-minimums/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/92-reverse-linked-list-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/983-minimum-cost-for-tickets/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/993-cousins-in-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/01.py:
--------------------------------------------------------------------------------
1 | print("Samir")
--------------------------------------------------------------------------------
/Basics-of-Python/DSA-problems/01.py:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/454-4sum-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0004-median-of-two-sorted-arrays/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0010-regular-expression-matching/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0124-binary-tree-maximum-path-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0129-sum-root-to-leaf-numbers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0151-reverse-words-in-a-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0171-excel-sheet-column-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0199-binary-tree-right-side-view/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0201-bitwise-and-of-numbers-range/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0208-implement-trie-prefix-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0222-count-complete-tree-nodes/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0238-product-of-array-except-self/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0368-largest-divisible-subset/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0374-guess-number-higher-or-lower/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0380-insert-delete-getrandom-o1/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0416-partition-equal-subset-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0513-find-bottom-left-tree-value/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0535-encode-and-decode-tinyurl/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0646-maximum-length-of-pair-chain/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0667-beautiful-arrangement-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0669-trim-a-binary-search-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0678-valid-parenthesis-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0713-subarray-product-less-than-k/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0790-domino-and-tromino-tiling/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0802-find-eventual-safe-states/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0823-binary-trees-with-factors/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0876-middle-of-the-linked-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0974-subarray-sums-divisible-by-k/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0981-time-based-key-value-store/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0983-minimum-cost-for-tickets/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/10-regular-expression-matching/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1004-max-consecutive-ones-iii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/104-maximum-depth-of-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1079-letter-tile-possibilities/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1106-parsing-a-boolean-expression/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1143-longest-common-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1162-as-far-from-land-as-possible/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1189-maximum-number-of-balloons/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1200-minimum-absolute-difference/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1207-unique-number-of-occurrences/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1220-count-vowels-permutation/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/124-binary-tree-maximum-path-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1268-search-suggestions-system/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/128-longest-consecutive-sequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1288-remove-covered-intervals/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1367-linked-list-in-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/138-copy-list-with-random-pointer/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1382-balance-a-binary-search-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/151-reverse-words-in-a-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1539-kth-missing-positive-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1631-path-with-minimum-effort/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1693-daily-leads-and-partners/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1710-maximum-units-on-a-truck/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/172-factorial-trailing-zeroes/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/173-binary-search-tree-iterator/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1795-rearrange-products-table/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1845-seat-reservation-manager/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1882-process-tasks-using-servers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1890-the-latest-login-in-2020/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1971-find-if-path-exists-in-graph/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1980-find-unique-binary-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/199-binary-tree-right-side-view/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/208-implement-trie-prefix-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/209-minimum-size-subarray-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/222-count-complete-tree-nodes/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/225-implement-stack-using-queues/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/230-kth-smallest-element-in-a-bst/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2304-minimum-path-cost-in-a-grid/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/232-implement-queue-using-stacks/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2360-longest-cycle-in-a-graph/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/237-delete-node-in-a-linked-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/238-product-of-array-except-self/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2409-count-days-spent-together/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/287-find-the-duplicate-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/295-find-median-from-data-stream/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/33-search-in-rotated-sorted-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/349-intersection-of-two-arrays/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/4-median-of-two-sorted-arrays/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/416-partition-equal-subset-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/435-non-overlapping-intervals/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/5-longest-palindromic-substring/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/535-encode-and-decode-tinyurl/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/538-convert-bst-to-greater-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/589-n-ary-tree-preorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/646-maximum-length-of-pair-chain/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/653-two-sum-iv-input-is-a-bst/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/662-maximum-width-of-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/713-subarray-product-less-than-k/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/720-longest-word-in-dictionary/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/769-max-chunks-to-make-sorted/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/823-binary-trees-with-factors/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/84-largest-rectangle-in-histogram/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/876-middle-of-the-linked-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/94-binary-tree-inorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/96-unique-binary-search-trees/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/973-k-closest-points-to-origin/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/974-subarray-sums-divisible-by-k/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/98-validate-binary-search-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/1146-snapshot-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/638-shopping-offers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0005-longest-palindromic-substring/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0094-binary-tree-inorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0102-binary-tree-level-order-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0144-binary-tree-preorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0145-binary-tree-postorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0166-fraction-to-recurring-decimal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0300-longest-increasing-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0318-maximum-product-of-word-lengths/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0357-count-numbers-with-unique-digits/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0373-find-k-pairs-with-smallest-sums/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0375-guess-number-higher-or-lower-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0406-queue-reconstruction-by-height/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0606-construct-string-from-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0688-knight-probability-in-chessboard/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0698-partition-to-k-equal-sum-subsets/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0787-cheapest-flights-within-k-stops/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0797-all-paths-from-source-to-target/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0894-all-possible-full-binary-trees/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0953-verifying-an-alien-dictionary/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0979-distribute-coins-in-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/102-binary-tree-level-order-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1027-longest-arithmetic-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1092-shortest-common-supersequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/114-flatten-binary-tree-to-linked-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/121-best-time-to-buy-and-sell-stock/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/122-best-time-to-buy-and-sell-stock-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1235-maximum-profit-in-job-scheduling/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1373-maximum-sum-bst-in-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1383-maximum-performance-of-a-team/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/144-binary-tree-preorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1444-number-of-ways-of-cutting-a-pizza/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1448-count-good-nodes-in-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1530-number-of-good-leaf-nodes-pairs/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1545-find-kth-bit-in-nth-binary-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1584-min-cost-to-connect-all-points/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/160-intersection-of-two-linked-lists/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1757-recyclable-and-low-fat-products/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/188-best-time-to-buy-and-sell-stock-iv/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1884-egg-drop-with-2-eggs-and-n-floors/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/19-remove-nth-node-from-end-of-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2024-maximize-the-confusion-of-an-exam/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/215-kth-largest-element-in-an-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2187-minimum-time-to-complete-trips/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2301-match-substring-after-replacement/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2321-maximum-score-of-spliced-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2348-number-of-zero-filled-subarrays/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/241-different-ways-to-add-parentheses/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2444-count-subarrays-with-fixed-bounds/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2448-minimum-cost-to-make-array-equal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2488-count-subarrays-with-median-k/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2597-the-number-of-beautiful-subsets/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/26-remove-duplicates-from-sorted-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/300-longest-increasing-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/387-first-unique-character-in-a-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/406-queue-reconstruction-by-height/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/516-longest-palindromic-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/540-single-element-in-a-sorted-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/583-delete-operation-for-two-strings/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/628-maximum-product-of-three-numbers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/688-knight-probability-in-chessboard/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/700-search-in-a-binary-search-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/703-kth-largest-element-in-a-stream/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/787-cheapest-flights-within-k-stops/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/797-all-paths-from-source-to-target/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/Highscore.txt:
--------------------------------------------------------------------------------
1 | 123
--------------------------------------------------------------------------------
/leetcode-cpp/1048-longest-string-chain/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/1291-sequential-digits/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/486-predict-the-winner/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/684-redundant-connection/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0017-letter-combinations-of-a-phone-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0114-flatten-binary-tree-to-linked-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0122-best-time-to-buy-and-sell-stock-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0329-longest-increasing-path-in-a-matrix/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0363-max-sum-of-rectangle-no-larger-than-k/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0467-unique-substrings-in-wraparound-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0530-minimum-absolute-difference-in-bst/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0958-check-completeness-of-a-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1038-binary-search-tree-to-greater-sum-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1071-greatest-common-divisor-of-strings/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1130-minimum-cost-tree-from-leaf-values/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1208-get-equal-substrings-within-budget/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1221-split-a-string-in-balanced-strings/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/123-best-time-to-buy-and-sell-stock-iii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1673-find-the-most-competitive-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/17-letter-combinations-of-a-phone-number/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1741-find-total-time-spent-by-each-employee/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1844-replace-all-digits-with-characters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1851-minimum-interval-to-include-each-query/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1898-maximum-number-of-removable-characters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1911-maximum-alternating-subsequence-sum/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1921-eliminate-maximum-number-of-monsters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1965-employees-with-missing-information/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2300-successful-pairs-of-spells-and-potions/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2302-count-subarrays-with-score-less-than-k/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2320-count-number-of-ways-to-place-houses/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/236-lowest-common-ancestor-of-a-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2423-remove-letter-to-equalize-frequency/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2452-words-within-two-edits-of-dictionary/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2565-subsequence-with-the-minimum-score/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/297-serialize-and-deserialize-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/329-longest-increasing-path-in-a-matrix/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/378-kth-smallest-element-in-a-sorted-matrix/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/421-maximum-xor-of-two-numbers-in-an-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/430-flatten-a-multilevel-doubly-linked-list/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/581-shortest-unsorted-continuous-subarray/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/80-remove-duplicates-from-sorted-array-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/921-minimum-add-to-make-parentheses-valid/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/958-check-completeness-of-a-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/1219-path-with-maximum-gold/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/1672-richest-customer-wealth/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/834-sum-of-distances-in-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0103-binary-tree-zigzag-level-order-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0109-convert-sorted-list-to-binary-search-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0211-design-add-and-search-words-data-structure/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0236-lowest-common-ancestor-of-a-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0378-kth-smallest-element-in-a-sorted-matrix/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0424-longest-repeating-character-replacement/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0452-minimum-number-of-arrows-to-burst-balloons/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0673-number-of-longest-increasing-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0689-maximum-sum-of-3-non-overlapping-subarrays/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0987-vertical-order-traversal-of-a-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1005-maximize-sum-of-array-after-k-negations/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1011-capacity-to-ship-packages-within-d-days/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/103-binary-tree-zigzag-level-order-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/108-convert-sorted-array-to-binary-search-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/109-convert-sorted-list-to-binary-search-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/116-populating-next-right-pointers-in-each-node/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1209-remove-all-adjacent-duplicates-in-string-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1318-minimum-flips-to-make-a-or-b-equal-to-c/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1342-number-of-steps-to-reduce-a-number-to-zero/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1423-maximum-points-you-can-obtain-from-cards/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1605-find-valid-matrix-given-row-and-column-sums/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1614-maximum-nesting-depth-of-the-parentheses/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1855-maximum-distance-between-a-pair-of-values/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1930-unique-length-3-palindromic-subsequences/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2091-removing-minimum-and-maximum-from-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/211-design-add-and-search-words-data-structure/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2271-maximum-white-tiles-covered-by-a-carpet/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2411-smallest-subarrays-with-maximum-bitwise-or/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2477-minimum-fuel-cost-to-report-to-the-capital/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2492-minimum-score-of-a-path-between-two-cities/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2508-add-edges-to-make-degrees-of-all-nodes-even/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/3-longest-substring-without-repeating-characters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/448-find-all-numbers-disappeared-in-an-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/452-minimum-number-of-arrows-to-burst-balloons/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/674-longest-continuous-increasing-subsequence/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/801-minimum-swaps-to-make-sequences-increasing/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/987-vertical-order-traversal-of-a-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/_config.yml:
--------------------------------------------------------------------------------
1 | theme: jekyll-theme-architect
--------------------------------------------------------------------------------
/leetcode-cpp/121-best-time-to-buy-and-sell-stock/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/1367-linked-list-in-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/438-find-all-anagrams-in-a-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0003-longest-substring-without-repeating-characters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0117-populating-next-right-pointers-in-each-node-ii/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0331-verify-preorder-serialization-of-a-binary-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0586-customer-placing-the-largest-number-of-orders/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1296-divide-array-in-sets-of-k-consecutive-numbers/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1309-decrypt-string-from-alphabet-to-integer-mapping/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1319-number-of-operations-to-make-network-connected/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1685-sum-of-absolute-differences-in-a-sorted-array/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2001-number-of-pairs-of-interchangeable-rectangles/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2006-count-number-of-pairs-with-absolute-difference-k/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/235-lowest-common-ancestor-of-a-binary-search-tree/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2546-apply-bitwise-operations-to-make-strings-equal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/309-best-time-to-buy-and-sell-stock-with-cooldown/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/849-maximize-distance-to-closest-person/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0028-find-the-index-of-the-first-occurrence-in-a-string/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0714-best-time-to-buy-and-sell-stock-with-transaction-fee/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1008-construct-binary-search-tree-from-preorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1312-minimum-insertion-steps-to-make-a-string-palindrome/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1347-minimum-number-of-steps-to-make-two-strings-anagram/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1461-check-if-a-string-contains-all-binary-codes-of-size-k/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1493-longest-subarray-of-1s-after-deleting-one-element/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1849-splitting-a-string-into-descending-consecutive-values/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1963-minimum-number-of-swaps-to-make-the-string-balanced/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1968-array-with-elements-not-equal-to-average-of-neighbors/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1974-minimum-time-to-type-word-using-special-typewriter/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/2449-minimum-number-of-operations-to-make-arrays-similar/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/714-best-time-to-buy-and-sell-stock-with-transaction-fee/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/29.py:
--------------------------------------------------------------------------------
1 | s = {}
2 | a = type(s)
3 | print(a)
--------------------------------------------------------------------------------
/ads.txt:
--------------------------------------------------------------------------------
1 | google.com, pub-8274401353019049, DIRECT, f08c47fec0942fa0
--------------------------------------------------------------------------------
/leetcode-cpp/1305-all-elements-in-two-binary-search-trees/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0105-construct-binary-tree-from-preorder-and-inorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0106-construct-binary-tree-from-inorder-and-postorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/105-construct-binary-tree-from-preorder-and-inorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/106-construct-binary-tree-from-inorder-and-postorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1466-reorder-routes-to-make-all-paths-lead-to-the-city-zero/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1581-customer-who-visited-but-did-not-make-any-transactions/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1866-number-of-ways-to-rearrange-sticks-with-k-sticks-visible/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/889-construct-binary-tree-from-preorder-and-postorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/LinkedList/Doubly Linked List/Circular Linked List .py:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/LinkedList/Singly Linked List/16_Doubly Linked List.py:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/1297-maximum-number-of-occurrences-of-a-substring/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/0889-construct-binary-tree-from-preorder-and-postorder-traversal/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1239-maximum-length-of-a-concatenated-string-with-unique-characters/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1888-minimum-number-of-flips-to-make-the-binary-string-alternating/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/15_Delete Any Node By Value in Linked List.py:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Table of 5.py:
--------------------------------------------------------------------------------
1 | for i in range(1,11):
2 | print(i*5)
3 |
--------------------------------------------------------------------------------
/1465-maximum-area-of-a-piece-of-cake-after-horizontal-and-vertical-cuts/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1509-minimum-difference-between-largest-and-smallest-value-in-three-moves/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/leetcode-cpp/1371-find-the-longest-substring-containing-vowels-in-even-counts/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/1334-find-the-city-with-the-smallest-number-of-neighbors-at-a-threshold-distance/NOTES.md:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/05_range_function.py:
--------------------------------------------------------------------------------
1 | for i in range(1, 8, 1):
2 | print(i)
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/Table of 5 (copy):
--------------------------------------------------------------------------------
1 | for i in range(1,11):
2 | print(i*5)
3 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/poem.txt:
--------------------------------------------------------------------------------
1 | twinkle twinkle little star how are wonder what you are!
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/Data-Stractures/15_Delete Any Node By Value in Linked List.py:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/leetcode-cpp/README.md:
--------------------------------------------------------------------------------
1 | # LeetCode
2 | Collection of LeetCode questions to ace the coding interview!
3 |
--------------------------------------------------------------------------------
/Basics-of-Python/DSA-problems/.vscode/settings.json:
--------------------------------------------------------------------------------
1 | {
2 | "python.pythonPath": "/usr/bin/python3.9"
3 | }
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/04.py:
--------------------------------------------------------------------------------
1 | a = [2,3,4,56,7,6]
2 | print(a)
3 | print(a[3])
4 | print(a[4])
5 |
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/28.py:
--------------------------------------------------------------------------------
1 | s = {2,2.00,4,"2",6}
2 | print(len(s)) # --->> it count 2 and 2.00 same
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/19.py:
--------------------------------------------------------------------------------
1 | string='I study Python at Coding Blocks'
2 | print(string[0:9:2])
3 |
4 |
5 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/20_Sets_.py:
--------------------------------------------------------------------------------
1 | a = {21,23,5,56,1,35,2,1,4,1,2,3,5}
2 | print(type(a))
3 | print(a)
4 |
--------------------------------------------------------------------------------
/BingSiteAuth.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 1A92FC2EC113F8616A21D76DA684A133
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/Sample.txt:
--------------------------------------------------------------------------------
1 | Samir is a student.
2 | He lives in Siliguri, Darjeeling, West Bengal
3 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/02.py:
--------------------------------------------------------------------------------
1 | sam = "Samir Paul is The Best"
2 | sam = sam.replace(" "," _#_ ")
3 | print(sam)
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/27.py:
--------------------------------------------------------------------------------
1 | # Set also prints int with String
2 | s = {2,3,4,5,5,5,5,"SamirPaul1"}
3 | print(s)
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/append.py:
--------------------------------------------------------------------------------
1 | f = open('text.txt','a')
2 | f.write("\nHELLO Bhai Kaha ho abhi")
3 | f.close
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/Dictionary Methods:
--------------------------------------------------------------------------------
1 | a = {“name”: “Harry”,
2 | “from”: “India”,
3 | “marks”: [92,98,96]}
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/in_Keyword.py:
--------------------------------------------------------------------------------
1 | a = [2,3,2,3,3,2434,3,3533,53,23]
2 | print(34 in a)
3 | print(3 in a)
4 |
5 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/01.py:
--------------------------------------------------------------------------------
1 | st = "Samir was the king of India"
2 | doublespaces = st.find(" ")
3 | print(doublespaces)
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/03.py:
--------------------------------------------------------------------------------
1 | letter = "Dear Samir Paul,\n\tThanks for helping me\ndate 16-Feb-2021"
2 | print(letter)
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/06_tuples.py:
--------------------------------------------------------------------------------
1 | # make a tuple with ()
2 | t = (1,2,5,67,2,1,111,1)
3 | print(t.count(2))
4 |
5 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/files.py:
--------------------------------------------------------------------------------
1 | f = open('Sample.txt')
2 | data = f.read()
3 | print(data)
4 | f.close()
5 |
6 |
7 |
--------------------------------------------------------------------------------
/Basics-of-Python/Git_Push_Commands.py:
--------------------------------------------------------------------------------
1 | git status
2 | git add .
3 | git status
4 | git commit -m"-----"
5 | git push
6 |
7 |
--------------------------------------------------------------------------------
/Basics-of-Python/Modules/dir/myfunction.py:
--------------------------------------------------------------------------------
1 | def add(a,b):
2 | return a+b
3 |
4 | def multiply(a,b):
5 | return a*b
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/08_continue_statement.py:
--------------------------------------------------------------------------------
1 | for i in range(10):
2 | if i == 5:
3 | continue
4 | print(i)
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/write a file.py:
--------------------------------------------------------------------------------
1 | f = open('sample.txt','w')
2 | f.write("I am Samir Paul")
3 |
4 | f.close
5 |
--------------------------------------------------------------------------------
/problems/to_lower_case/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def toLowerCase(self, s: str) -> str:
3 | return s.lower()
--------------------------------------------------------------------------------
/.gitmodules:
--------------------------------------------------------------------------------
1 | [submodule "themes/PaperMod"]
2 | path = themes/PaperMod
3 | url = https://github.com/adityatelange/hugo-PaperMod
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/Celcious to ferenhite.py:
--------------------------------------------------------------------------------
1 | def ferh(cel):
2 | return (cel*(9/5)) + 32
3 | print(ferh(100))
4 |
5 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/is_Keyword.py:
--------------------------------------------------------------------------------
1 | a = None
2 | if(a is None):
3 | print("Yes")
4 | else:
5 | print("no")
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/09_sum_of_list.py:
--------------------------------------------------------------------------------
1 | a = [3,45,65,24,66,2,65]
2 | print(sum(a))
3 | # print(a[0]+a[1]+a[2]+a[3]+a[4]+a[5]+a[6])
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/06_for_with_else.py:
--------------------------------------------------------------------------------
1 | for i in range(10):
2 | print(i)
3 | else:
4 | print("This is inside else of for")
--------------------------------------------------------------------------------
/Basics-of-Python/Inheritence+Module/dir/myfunction.py:
--------------------------------------------------------------------------------
1 | def add(a,b):
2 | return a+b
3 |
4 | def multiply(a,b):
5 | return a*b
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/comment.txt:
--------------------------------------------------------------------------------
1 | @#$%@ @#$%@ , asad, ewrw
2 | safe
3 | @#$%@, adw,erw
4 | @#$%@
5 | good
6 | best @#$%@
7 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/15_check prime no.py:
--------------------------------------------------------------------------------
1 | def count_recursive(n=1):
2 | if n > 3:
3 | return:
4 | print(n)
5 | count_recursive(n + 1)
--------------------------------------------------------------------------------
/Basics-of-Python/The break statement.py:
--------------------------------------------------------------------------------
1 | for i in range(0, 80):
2 | print(i) #This will print 0, 1, 2 and 3
3 | if i == 3:
4 | break
5 |
--------------------------------------------------------------------------------
/1527-patients-with-a-condition/1527-patients-with-a-condition.sql:
--------------------------------------------------------------------------------
1 | select * from Patients where conditions like "DIAB1%" or conditions like "% DIAB1%"
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/01_import _os.listdir.py:
--------------------------------------------------------------------------------
1 | # This shows all the fies in the respective folder
2 | import os
3 | print(os.listdir())
4 |
--------------------------------------------------------------------------------
/assets/long-banner-breck-img-readme-unnamed.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/SamirPaulb/LeetCode/HEAD/assets/long-banner-breck-img-readme-unnamed.png
--------------------------------------------------------------------------------
/0182-duplicate-emails/0182-duplicate-emails.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select email from person
3 | group by email having count(id) > 1;
--------------------------------------------------------------------------------
/0441-arranging-coins/0441-arranging-coins.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def arrangeCoins(self, n: int) -> int:
3 | return int((-1 + (1+4*n*2)**(1/2))//2)
--------------------------------------------------------------------------------
/Basics-of-Python/07_reduce.py:
--------------------------------------------------------------------------------
1 | from functools import reduce
2 |
3 | sum = lambda a, b: a+b
4 |
5 | l = [1, 2, 3, 4]
6 | val = reduce(sum, l)
7 | print(val)
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/The break statement (copy):
--------------------------------------------------------------------------------
1 | for i in range(0, 80):
2 | print(i) #This will print 0, 1, 2 and 3
3 | if i == 3:
4 | break
5 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/Multiplication table in reverse order.py:
--------------------------------------------------------------------------------
1 | n = 5
2 | for i in range(10):
3 | print(f'5 X {10-i} = {n*(10-i)}')
4 |
5 |
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/modi.py:
--------------------------------------------------------------------------------
1 | i = 1
2 | for i in range(1,4):
3 | print("MODI + BJP + 👍 VOTE BJP in WEST BENGAL 2021 👍 Election ✔️ ❤️🔥❤️")
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/02_if_else_quick_quiz.py:
--------------------------------------------------------------------------------
1 | age = int(input("Enter your age: "))
2 |
3 | if age>18:
4 | print("Yes")
5 | else:
6 | print("No")
--------------------------------------------------------------------------------
/Basics-of-Python/Trick to reverse a string in python.py:
--------------------------------------------------------------------------------
1 | # Trick to reverse a string in python:
2 |
3 | a = "Hello, I am Samir Paul"
4 | print(a[::-1])
5 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/sample.txt:
--------------------------------------------------------------------------------
1 | hello world !
2 | 23333333333333333333333333333
3 | 23333333333333333333333333333
4 | 23333333333333333333333333333
--------------------------------------------------------------------------------
/162-find-peak-element/NOTES.md:
--------------------------------------------------------------------------------
1 | Instead of writting mid = (l + r) // 2 we should write mid = l + (r - l) // 2 because of INTEGER OVERFLOW in the former case
2 |
--------------------------------------------------------------------------------
/Basics-of-Python/For loop with else.py:
--------------------------------------------------------------------------------
1 | l = [1, 7, 8]
2 | for item in l:
3 | print(item)
4 | else:
5 | print(“Done”) #This is printed when the loop exhausts!
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/Operatos and expressions.py:
--------------------------------------------------------------------------------
1 | a= 10+10
2 | a= 1-20
3 | a= 2*5
4 | a= 10**5
5 | a= 10/2
6 | a= 10%3
7 | a= 10/3000
8 |
9 | print(a)
10 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/04_print_list_for.py:
--------------------------------------------------------------------------------
1 | fruits = ['Banana', 'Watermelon', 'Grapes', 'Mangoes']
2 |
3 | for item in fruits:
4 | print(item)
5 |
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/10_pr_04.py:
--------------------------------------------------------------------------------
1 | l = [1, 2, 3, 4, 5, 6, 7, 8, 9, 1, 2, 3, 4, 54, 23, 55, 90, 60]
2 |
3 | a = filter(lambda a: a%5==0, l)
4 | print(list(a))
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/04_print_list_for.py:
--------------------------------------------------------------------------------
1 | fruits = ['Banana', 'Watermelon', 'Grapes', 'Mangoes']
2 |
3 | for item in fruits:
4 | print(item)
5 |
6 |
--------------------------------------------------------------------------------
/problems/partitioning_into_minimum_number_of_deci-binary_numbers/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def minPartitions(self, n: str) -> int:
3 | return max(n)
--------------------------------------------------------------------------------
/0584-find-customer-referee/0584-find-customer-referee.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select name from Customer where referee_id != 2 or referee_id is null;
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/cote to specify strings:
--------------------------------------------------------------------------------
1 | a = '''Samir'''
2 | # a = "Samir"
3 | # a = 'Samir'
4 | b = 343.55
5 | c = 45
6 | print(a)
7 | print(b)
8 | print(c)
9 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/05_is_else_optional.py:
--------------------------------------------------------------------------------
1 | a = 6
2 | if(a==7):
3 | print("yes")
4 | elif(a>56):
5 | print("no and yes")
6 | else:
7 | print("I am optional")
--------------------------------------------------------------------------------
/Basics-of-Python/The continue statement.py:
--------------------------------------------------------------------------------
1 | for i in range(4):
2 | print(“printing”)
3 | if i == 2: #if i is 2, the iteration is skipped
4 | continue
5 | print(i)
6 |
--------------------------------------------------------------------------------
/0511-game-play-analysis-i/0511-game-play-analysis-i.sql:
--------------------------------------------------------------------------------
1 | SELECT
2 | A.player_id,
3 | MIN(A.event_date) AS first_login
4 | FROM
5 | Activity A
6 | GROUP BY
7 | A.player_id;
--------------------------------------------------------------------------------
/0595-big-countries/0595-big-countries.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | SELECT name, population, area FROM World WHERE population >= 25000000 OR area >= 3000000;
--------------------------------------------------------------------------------
/1148-article-views-i/1148-article-views-i.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select distinct author_id as id from Views where author_id = viewer_id order by id asc;
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/07_break_statement.py:
--------------------------------------------------------------------------------
1 | for i in range(10):
2 | print(i)
3 | if i == 5:
4 | break
5 | else:
6 | print("This is inside else of for")
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/For loop with else (copy):
--------------------------------------------------------------------------------
1 | l = [1, 7, 8]
2 | for item in l:
3 | print(item)
4 | else:
5 | print(“Done”) #This is printed when the loop exhausts!
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/04_in_and_is.py:
--------------------------------------------------------------------------------
1 | # a = None
2 | # if (a is None):
3 | # print("Yes")
4 | # else:
5 | # print("No")
6 |
7 | a = [45, 56, 6]
8 | print(435 in a)
--------------------------------------------------------------------------------
/Basics-of-Python/Queue Data-Stracture/Trick to reverse a string in python.py:
--------------------------------------------------------------------------------
1 | # Trick to reverse a string in python:
2 |
3 | a = "Hello, I am Samir Paul"
4 | print(a[::-1])
5 |
--------------------------------------------------------------------------------
/leetcode-cpp/number-of-1-bits/number-of-1-bits.cpp:
--------------------------------------------------------------------------------
1 | class Solution {
2 | public:
3 | int hammingWeight(uint32_t n) {
4 | return __builtin_popcount(n);
5 | }
6 | };
--------------------------------------------------------------------------------
/292_Nim_Game.py:
--------------------------------------------------------------------------------
1 | class Solution(object):
2 | def canWinNim(self, n):
3 | """
4 | :type n: int
5 | :rtype: bool
6 | """
7 | return n % 4 != 0
--------------------------------------------------------------------------------
/Basics-of-Python/Syntax.py:
--------------------------------------------------------------------------------
1 | ''' a = {“key”: “value”,
2 | “harry”: “code”,
3 | “marks” : “100”,
4 | “list”: [1,2,9]}
5 | a[“key”] # Prints value
6 | a[“list”] # Prints [1,2,9] '''
7 |
--------------------------------------------------------------------------------
/problems/check_if_the_sentence_is_pangram/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def checkIfPangram(self, sentence: str) -> bool:
3 | return len(set(sentence)) ==26
4 |
--------------------------------------------------------------------------------
/problems/count_negative_numbers_in_a_sorted_matrix/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def countNegatives(self, grid: List[List[int]]) -> int:
3 | return str(grid).count('-')
--------------------------------------------------------------------------------
/Basics-of-Python/04_print memory location.py:
--------------------------------------------------------------------------------
1 | class Node:
2 | def __init__(self,data):
3 | self.data = data
4 | self.ref = None
5 |
6 | LL = Node(10)
7 | print(LL)
8 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/The continue statement (copy):
--------------------------------------------------------------------------------
1 | for i in range(4):
2 | print(“printing”)
3 | if i == 2: #if i is 2, the iteration is skipped
4 | continue
5 | print(i)
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/Queue Data-Stracture/02.py:
--------------------------------------------------------------------------------
1 | a = "Hello World!"
2 | def reverse(a):
3 | s = ""
4 | for i in a:
5 | s = i + s
6 | return s
7 |
8 | print(reverse(a))
9 |
--------------------------------------------------------------------------------
/problems/find_the_index_of_the_first_occurrence_in_a_string/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def strStr(self, haystack: str, needle: str) -> int:
3 | return haystack.find(needle)
--------------------------------------------------------------------------------
/problems/missing_number/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def missingNumber(self, nums: List[int]) -> int:
3 | n = len(nums)
4 |
5 | return n*(n+1)//2 - sum(nums)
--------------------------------------------------------------------------------
/0197-rising-temperature/0197-rising-temperature.sql:
--------------------------------------------------------------------------------
1 | SELECT w1.id
2 | FROM Weather AS w1 , Weather AS w2
3 | WHERE w1.Temperature > w2.Temperature AND DATEDIFF(w1.recordDate , w2.recordDate) = 1
--------------------------------------------------------------------------------
/0627-swap-salary/0627-swap-salary.sql:
--------------------------------------------------------------------------------
1 | update Salary
2 | set sex = if (sex = 'm', 'f', 'm');
3 |
4 |
5 |
6 | # update Salary
7 | # set sex = case sex when 'm' then 'f' else 'm' end;
8 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/ends_function.py:
--------------------------------------------------------------------------------
1 | print("Hello",end=" ")
2 | print("there",end=" ")
3 | print("I am",end=" ")
4 | print("Samir",end=" ")
5 | print("Paul",end=" ")
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/18_use of Strip_Function.py:
--------------------------------------------------------------------------------
1 | a = input("Write the number here:\n ")
2 | if a.strip() == "yes":
3 | print("True")
4 |
5 | else:
6 | print("False")
7 |
8 |
--------------------------------------------------------------------------------
/leetcode-cpp/delete-duplicate-emails/delete-duplicate-emails.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | DELETE P1
3 | FROM PERSON P1, PERSON P2
4 | WHERE P1.EMAIL=P2.EMAIL AND P1.ID>P2.ID;
--------------------------------------------------------------------------------
/1323_Maximum_69_Number.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def maximum69Number (self, num: int) -> int:
3 | # Replace first 6 with 9 if exists
4 | return(str(num).replace('6', '9', 1))
5 |
--------------------------------------------------------------------------------
/1757-recyclable-and-low-fat-products/1757-recyclable-and-low-fat-products.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | SELECT product_id from Products where low_fats = "Y" and recyclable = "Y";
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/04_try_with_else.py:
--------------------------------------------------------------------------------
1 | try:
2 | i = int(input("Enter a number: "))
3 | c = 1/i
4 | except Exception as e:
5 | print(e)
6 | else:
7 | print("We were successful")
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/25_instance_.py:
--------------------------------------------------------------------------------
1 | # a = 23
2 | a = "Samir"
3 | print(type(a))
4 | # now check wheather evrything in Python is Objet oriyented or not
5 | print(isinstance(a,object))
6 |
7 |
--------------------------------------------------------------------------------
/Basics-of-Python/To take values from the User.py:
--------------------------------------------------------------------------------
1 | a = input("type value of number a here: ")
2 | b = input("type value of number b here: ")
3 | print("The sum of numbers a and b is: ", a+b)
4 |
--------------------------------------------------------------------------------
/1729-find-followers-count/1729-find-followers-count.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select user_id, count(*) as followers_count from followers group by user_id order by user_id asc;
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/09_05_pr_01.py:
--------------------------------------------------------------------------------
1 | f = open('poems.txt')
2 | t = f.read()
3 | if 'twinkle' in t:
4 | print("Twinkle is present")
5 | else:
6 | print("Twinkle is not present")
7 | f.close()
--------------------------------------------------------------------------------
/problems/gray_code/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def grayCode(self, n):
3 | if n == 0: return [0]
4 | t = self.grayCode(n-1)
5 | return t + [i+(1<<(n-1)) for i in t][::-1]
--------------------------------------------------------------------------------
/problems/single_number/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def singleNumber(self, nums: List[int]) -> int:
3 | for i in nums:
4 | if nums.count(i) == 1:
5 | return i
--------------------------------------------------------------------------------
/0197-rising-temperature/NOTES.md:
--------------------------------------------------------------------------------
1 | ```mysql
2 |
3 | SELECT w1.id
4 | FROM Weather AS w1 , Weather AS w2
5 | WHERE w1.Temperature > w2.Temperature AND DATEDIFF(w1.recordDate , w2.recordDate) = 1
6 |
7 | ```
--------------------------------------------------------------------------------
/344_Reverse_String.py:
--------------------------------------------------------------------------------
1 | class Solution(object):
2 | def reverseString(self, s):
3 | """
4 | :type s: str
5 | :rtype: str
6 | """
7 | # slice
8 | return s[::-1]
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/Py Practice:
--------------------------------------------------------------------------------
1 | a = 1
2 | b = 23
3 | print(a/b)
4 | print(a*b)
5 | print(a-b)
6 | print(a+b)
7 | print(a**b)
8 | print("%0.4f"%(a/b))
9 | print(a//b)
10 | print(a%b)
11 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/elif clause:
--------------------------------------------------------------------------------
1 | '''
2 | if (condition1):
3 | #code
4 | elif (condition 2):
5 | #code
6 | elif (condition 2):
7 | #code
8 | ….
9 | else:
10 | #code '''
11 |
--------------------------------------------------------------------------------
/0136-single-number/0136-single-number.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def singleNumber(self, nums: List[int]) -> int:
3 | res = 0
4 | for n in nums:
5 | res = res ^ n
6 | return res
--------------------------------------------------------------------------------
/0175-combine-two-tables/0175-combine-two-tables.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select firstName, lastname, city, state from Person left join Address on Person.personId = Address.personId;
3 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/To take values from the User (copy):
--------------------------------------------------------------------------------
1 | a = input("type value of number a here: ")
2 | b = input("type value of number b here: ")
3 | print("The sum of numbers a and b is: ", a+b)
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Modules/rectangle.py:
--------------------------------------------------------------------------------
1 | from Polygon import Polygon
2 | from shape import Shape
3 |
4 | class Rectangle(Polygon,Shape):
5 | def area(self):
6 | return self.get_height()*self.get_width()
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/33.py:
--------------------------------------------------------------------------------
1 | print('''Samir Paul is the best guy in the world.
2 | He will be the King of the world''')
3 | print("He is the best Python coder in the world")
4 | print("# I Am The Bast")
5 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/Data-Stractures/04_print memory location.py:
--------------------------------------------------------------------------------
1 | class Node:
2 | def __init__(self,data):
3 | self.data = data
4 | self.ref = None
5 |
6 | LL = Node(10)
7 | print(LL)
8 |
--------------------------------------------------------------------------------
/0607-sales-person/0607-sales-person.sql:
--------------------------------------------------------------------------------
1 | select s.name
2 | from Orders o join Company c on (o.com_id = c.com_id and c.name = 'RED')
3 | right join SalesPerson s on s.sales_id = o.sales_id
4 | where o.sales_id is null;
--------------------------------------------------------------------------------
/1393-capital-gain-loss/1393-capital-gain-loss.sql:
--------------------------------------------------------------------------------
1 | select stock_name,
2 | sum(case when operation = 'Buy' then -price
3 | else price
4 | end) as capital_gain_loss
5 | from Stocks
6 | group by stock_name
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/To take values from the User (3rd copy):
--------------------------------------------------------------------------------
1 | a = input("type value of number a here: ")
2 | b = input("type value of number b here: ")
3 | print("The sum of numbers a and b is: ", a+b)
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/To take values from the User (4th copy):
--------------------------------------------------------------------------------
1 | a = input("type value of number a here: ")
2 | b = input("type value of number b here: ")
3 | print("The sum of numbers a and b is: ", a+b)
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/To take values from the User (5th copy):
--------------------------------------------------------------------------------
1 | a = input("type value of number a here: ")
2 | b = input("type value of number b here: ")
3 | print("The sum of numbers a and b is: ", a+b)
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/To take values from the User (6th copy):
--------------------------------------------------------------------------------
1 | a = input("type value of number a here: ")
2 | b = input("type value of number b here: ")
3 | print("The sum of numbers a and b is: ", a+b)
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/To take values from the User (7th copy):
--------------------------------------------------------------------------------
1 | a = input("type value of number a here: ")
2 | b = input("type value of number b here: ")
3 | print("The sum of numbers a and b is: ", a+b)
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/LinkedList/Singly Linked List/04_print memory location.py:
--------------------------------------------------------------------------------
1 | class Node:
2 | def __init__(self,data):
3 | self.data = data
4 | self.ref = None
5 |
6 | LL = Node(10)
7 | print(LL)
8 |
--------------------------------------------------------------------------------
/Basics-of-Python/Modules/triangle.py:
--------------------------------------------------------------------------------
1 | from Polygon import Polygon
2 | from shape import Shape
3 | class Triangle(Polygon,Shape):
4 | def area(self):
5 | return (self.get_width()*self.get_height())/2
6 |
7 |
--------------------------------------------------------------------------------
/Basics-of-Python/My First Python Code.py:
--------------------------------------------------------------------------------
1 | # I am writing comments:
2 | '''
3 | Hello
4 | Samir Paul
5 | SAGAR
6 | '''
7 | print("Hello")
8 | print("Samir Paul")
9 | print("Sagar Paul")
10 | print("SAGAR")
11 |
--------------------------------------------------------------------------------
/0183-customers-who-never-order/0183-customers-who-never-order.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select Customers.name as 'Customers' from Customers where Customers.id not in (select customerId from Orders)
--------------------------------------------------------------------------------
/Basics-of-Python/03_raising_exceptions.py:
--------------------------------------------------------------------------------
1 | def increment(num):
2 | try:
3 | return int(num) + 1
4 | except:
5 | raise ValueError("This is not good - Harry")
6 |
7 | a = increment('df364')
8 | print(a)
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/To take values from the User (another copy):
--------------------------------------------------------------------------------
1 | a = input("type value of number a here: ")
2 | b = input("type value of number b here: ")
3 | print("The sum of numbers a and b is: ", a+b)
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Inheritence+Module/rectangle.py:
--------------------------------------------------------------------------------
1 | from Polygon import Polygon
2 | from shape import Shape
3 |
4 | class Rectangle(Polygon,Shape):
5 | def area(self):
6 | return self.get_height()*self.get_width()
--------------------------------------------------------------------------------
/Basics-of-Python/Modules/shape.py:
--------------------------------------------------------------------------------
1 | class Shape:
2 | __colour = None
3 |
4 | def set_colour(self,colour):
5 | self.__colour = colour
6 | def get_colour(self):
7 | return self.__colour
8 |
9 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/03_logical_and_relational_operators.py:
--------------------------------------------------------------------------------
1 | age = int(input("Enter your age: "))
2 | if(age>34 or age<56):
3 | print("You can work with us")
4 |
5 | else:
6 | print("You cannot work with us")
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/09_08_pr_04.py:
--------------------------------------------------------------------------------
1 | with open("sample.txt") as f:
2 | content = f.read()
3 |
4 | content = content.replace("donkey", "$%^@$^#")
5 |
6 | with open("sample.txt", "w") as f:
7 | f.write(content)
--------------------------------------------------------------------------------
/Basics-of-Python/Queue Data-Stracture/06.py:
--------------------------------------------------------------------------------
1 | n = ["a","b","a","b","a","a"]
2 |
3 | l = int(len(n))
4 |
5 | for i in range(l-1):
6 | if n[i] == n[i+1]:
7 | l1 = n.remove(n[i])
8 | print(l1)
9 |
10 |
--------------------------------------------------------------------------------
/Basics-of-Python/Recursion.py:
--------------------------------------------------------------------------------
1 | def factorial(n):
2 | if i == 0 or i == 1 : #Base condition which doesn’t call the function any further
3 | return i
4 | else:
5 | return n*factorial(n-1) #Function calling itself
6 |
--------------------------------------------------------------------------------
/problems/lucky_numbers_in_a_matrix/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def luckyNumbers(self, matrix: List[List[int]]) -> List[int]:
3 | return list({min(row) for row in matrix} & {max(col) for col in zip(*matrix)})
--------------------------------------------------------------------------------
/problems/maximum_product_difference_between_two_pairs/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def maxProductDifference(self, nums: List[int]) -> int:
3 | nums.sort()
4 | return nums[-1]*nums[-2] - nums[0]*nums[1]
--------------------------------------------------------------------------------
/problems/power_of_four/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def isPowerOfFour(self, n: int) -> bool:
3 | while n > 1:
4 | if n % 4 != 0 : return False
5 | n = n // 4
6 | return n == 1
--------------------------------------------------------------------------------
/problems/power_of_three/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def isPowerOfThree(self, n: int) -> bool:
3 | while n > 1:
4 | if n % 3 != 0: return False
5 | n = n //3
6 | return n == 1
--------------------------------------------------------------------------------
/problems/valid_anagram/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def isAnagram(self, s: str, t: str) -> bool:
3 | s = list(s)
4 | s.sort()
5 | t = list(t)
6 | t.sort()
7 | return s == t
8 |
--------------------------------------------------------------------------------
/1873-calculate-special-bonus/1873-calculate-special-bonus.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select employee_id, salary * (employee_id%2) * (name not like "M%") as bonus
3 | from Employees
4 | order by employee_id;
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/14.py:
--------------------------------------------------------------------------------
1 |
2 | ints = [1, 2, 88, -100, 49]
3 | total = 0
4 | for i in range(len(ints)):
5 | total = total + ints[i]
6 | if total < 0:
7 | break
8 | print (ints[i])
9 |
10 |
11 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/32.py:
--------------------------------------------------------------------------------
1 | a = "Welcome to 30 Days of Code!"
2 | if a.strip() == "Welcome to 30 Days of Code!" :
3 | print('''Hello, World.
4 | Welcome to 30 Days of Code!''')
5 | else:
6 | print("Nothing to show")
--------------------------------------------------------------------------------
/problems/counting_bits/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def countBits(self, n: int) -> List[int]:
3 |
4 | ans = []
5 | for i in range(n+1):
6 | ans.append(bin(i).count('1'))
7 | return ans
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/Length_of_a_Password.py:
--------------------------------------------------------------------------------
1 | a = input("Write the password here: \n")
2 | if(len(a)<8):
3 | print("Type a Strong Password with more than 8 charecter")
4 | else:
5 | print("Strong Password")
6 |
--------------------------------------------------------------------------------
/Basics-of-Python/Inheritence+Module/shape.py:
--------------------------------------------------------------------------------
1 | class Shape:
2 | __colour = None
3 |
4 | def set_colour(self,colour):
5 | self.__colour = colour
6 | def get_colour(self):
7 | return self.__colour
8 |
9 |
--------------------------------------------------------------------------------
/Basics-of-Python/Inheritence+Module/triangle.py:
--------------------------------------------------------------------------------
1 | from Polygon import Polygon
2 | from shape import Shape
3 | class Triangle(Polygon,Shape):
4 | def area(self):
5 | return (self.get_width()*self.get_height())/2
6 |
7 |
--------------------------------------------------------------------------------
/Basics-of-Python/Object_Oriented_Programming/03.py:
--------------------------------------------------------------------------------
1 | class Animal:
2 | name = "dog"
3 | def color(self, colourName):
4 | print(self.name," is ",colourName)
5 |
6 |
7 |
8 | animal = Animal()
9 | animal.color("black")
--------------------------------------------------------------------------------
/Basics-of-Python/Object_Oriented_Programming/2-D array.py:
--------------------------------------------------------------------------------
1 | import numpy
2 |
3 | arr1 = ([
4 | [1,2,3],
5 | [4,5,6],
6 | [7,8,9]
7 |
8 |
9 | ])
10 |
11 | print(arr1)
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/Queue Data-Stracture/04.py:
--------------------------------------------------------------------------------
1 | import collections
2 | q = collections.deque()
3 | print(not q)
4 | q.append(10)
5 | q.append(20)
6 | q.append(30)
7 | q.append(40)
8 | q.append(50)
9 | print(q)
10 |
11 |
12 |
--------------------------------------------------------------------------------
/0191-number-of-1-bits/0191-number-of-1-bits.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def hammingWeight(self, n: int) -> int:
3 | res = 0
4 | for i in range(32):
5 | if n&(1<& nums) {
4 | int ans=0;
5 | for(auto i: nums)
6 | ans^=i;
7 | return ans;
8 | }
9 | };
--------------------------------------------------------------------------------
/0190-reverse-bits/0190-reverse-bits.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def reverseBits(self, n: int) -> int:
3 | res = 0
4 | for i in range(32):
5 | if n&(1<0:
10 | pass
11 |
12 | while i>6:
13 | pass
14 |
15 | print("Harry is a good boy")
--------------------------------------------------------------------------------
/Basics-of-Python/If elif else.py:
--------------------------------------------------------------------------------
1 | a = 2
2 | if a>0 :
3 | print("Positive")
4 | elif a==-5:
5 | print("-Five")
6 | elif a ==0:
7 | print("Zero")
8 | elif a ==-2:
9 | print("-Two")
10 | else:
11 | print("Negative")
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/LexycoGrafic Operators Order.py:
--------------------------------------------------------------------------------
1 | a = 10>4
2 | print(a)
3 | a = "abc" >"yz"
4 | print(a)
5 | a = "abc" >"ABC"
6 | print(a)
7 | a = ord("A")
8 | print(a)
9 | a = ord("a")
10 | print(a)
11 | a = ord("x")
12 | print(a)
13 |
--------------------------------------------------------------------------------
/Basics-of-Python/__init__ constructor.py:
--------------------------------------------------------------------------------
1 | class Employee:
2 | def __init__(self,name):
3 | self.name = name
4 | def getSalary(self):
5 | #Some code…
6 | harry = Employee(“Harry”) #Object can be instantiated using constructor like this!
7 |
--------------------------------------------------------------------------------
/problems/contains_duplicate/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def containsDuplicate(self, nums: List[int]) -> bool:
3 | arr_len = len(nums)
4 | set_len = len(set(nums))
5 |
6 | return arr_len != set_len
7 |
--------------------------------------------------------------------------------
/problems/defanging_an_ip_address/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def defangIPaddr(self, address: str) -> str:
3 | address = str(address)
4 | address = address.replace(".","[.]")
5 | return address
6 |
7 |
8 |
--------------------------------------------------------------------------------
/0070-climbing-stairs/0070-climbing-stairs.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def climbStairs(self, n: int) -> int:
3 | dp = [0, 1, 2]
4 | for i in range(3, n+1):
5 | dp.append(dp[i-2] + dp[i-1])
6 |
7 | return dp[n]
--------------------------------------------------------------------------------
/Basics-of-Python/05_map.py:
--------------------------------------------------------------------------------
1 | def square(num):
2 | return num*num
3 |
4 | l = [1, 2, 4]
5 |
6 | # Method 1
7 | l2 = []
8 | for item in l:
9 | l2.append(square(item))
10 | print(l2)
11 |
12 | # Method 2
13 | print(list(map(square, l)))
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/09_enumerate.py:
--------------------------------------------------------------------------------
1 | list1 = [3, 53, 2, False, 6.2, "Harry"]
2 |
3 | # index = 0
4 | # for item in list1:
5 | # print(item, index)
6 | # index += 1
7 |
8 | for index, item in enumerate(list1):
9 | print(item, index)
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/multiplication table 2 to 20 in different files by for loop/ZIP_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/SamirPaulb/LeetCode/HEAD/Basics-of-Python/chapter3 .py/multiplication table 2 to 20 in different files by for loop/ZIP_1.png
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_1.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 1 is Written below:
2 | 1 X 1 = 1
3 | 1 X 2 = 2
4 | 1 X 3 = 3
5 | 1 X 4 = 4
6 | 1 X 5 = 5
7 | 1 X 6 = 6
8 | 1 X 7 = 7
9 | 1 X 8 = 8
10 | 1 X 9 = 9
11 | 1 X 10 = 10
12 |
--------------------------------------------------------------------------------
/leetcode-cpp/employees-earning-more-than-their-managers/employees-earning-more-than-their-managers.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | SELECT a.NAME as Employee FROM EMPLOYEE as a, EMPLOYEE as b WHERE a.ManagerId=b.Id and a.SALARY>b.salary;
--------------------------------------------------------------------------------
/problems/rotate_array/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def rotate(self, nums: List[int], k: int) -> None:
3 | for i in range(k):
4 | a = nums.pop()
5 | nums.insert(0, a)
6 |
7 | return nums
8 |
--------------------------------------------------------------------------------
/1189-maximum-number-of-balloons/1189-maximum-number-of-balloons.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def maxNumberOfBalloons(self, text: str) -> int:
3 | cd = collections.Counter(text)
4 | return min(cd['b'], cd['a'], cd['l']//2, cd['o']//2, cd['n'])
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/If else and elif in Python (copy):
--------------------------------------------------------------------------------
1 | '''
2 | if (condition1): // if condition 1 is true
3 | print(“yes”)
4 | elif (condition2): // if condition 2 is true
5 | print(“No”)
6 | else: // otherwise
7 | print(“May be”)
8 | '''
9 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/22properties of sets.py:
--------------------------------------------------------------------------------
1 | a = set() # an Empty set
2 | # we are adding values into the empty set
3 | a.add(3)
4 | a.add(4)
5 | a.add(5)
6 | a.add(6)
7 | a.add(10)
8 | a.remove(6)
9 |
10 | print(len(a))
11 | print(a)
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/Static method.py:
--------------------------------------------------------------------------------
1 | class Employee:
2 | company = “Google”
3 | def getSalary(self):
4 | print(“Salary is not there”)
5 |
6 | @staticmethod #decorator to mark greet as a static method
7 | def greet():
8 | print(“Hello user”)
9 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/multiplication table 2 to 20 in different files by for loop/python.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/SamirPaulb/LeetCode/HEAD/Basics-of-Python/chapter3 .py/multiplication table 2 to 20 in different files by for loop/python.gif
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_2.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 2 is Written below:
2 | 2 X 1 = 2
3 | 2 X 2 = 4
4 | 2 X 3 = 6
5 | 2 X 4 = 8
6 | 2 X 5 = 10
7 | 2 X 6 = 12
8 | 2 X 7 = 14
9 | 2 X 8 = 16
10 | 2 X 9 = 18
11 | 2 X 10 = 20
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_3.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 3 is Written below:
2 | 3 X 1 = 3
3 | 3 X 2 = 6
4 | 3 X 3 = 9
5 | 3 X 4 = 12
6 | 3 X 5 = 15
7 | 3 X 6 = 18
8 | 3 X 7 = 21
9 | 3 X 8 = 24
10 | 3 X 9 = 27
11 | 3 X 10 = 30
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_4.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 4 is Written below:
2 | 4 X 1 = 4
3 | 4 X 2 = 8
4 | 4 X 3 = 12
5 | 4 X 4 = 16
6 | 4 X 5 = 20
7 | 4 X 6 = 24
8 | 4 X 7 = 28
9 | 4 X 8 = 32
10 | 4 X 9 = 36
11 | 4 X 10 = 40
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_5.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 5 is Written below:
2 | 5 X 1 = 5
3 | 5 X 2 = 10
4 | 5 X 3 = 15
5 | 5 X 4 = 20
6 | 5 X 5 = 25
7 | 5 X 6 = 30
8 | 5 X 7 = 35
9 | 5 X 8 = 40
10 | 5 X 9 = 45
11 | 5 X 10 = 50
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_6.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 6 is Written below:
2 | 6 X 1 = 6
3 | 6 X 2 = 12
4 | 6 X 3 = 18
5 | 6 X 4 = 24
6 | 6 X 5 = 30
7 | 6 X 6 = 36
8 | 6 X 7 = 42
9 | 6 X 8 = 48
10 | 6 X 9 = 54
11 | 6 X 10 = 60
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_7.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 7 is Written below:
2 | 7 X 1 = 7
3 | 7 X 2 = 14
4 | 7 X 3 = 21
5 | 7 X 4 = 28
6 | 7 X 5 = 35
7 | 7 X 6 = 42
8 | 7 X 7 = 49
9 | 7 X 8 = 56
10 | 7 X 9 = 63
11 | 7 X 10 = 70
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_8.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 8 is Written below:
2 | 8 X 1 = 8
3 | 8 X 2 = 16
4 | 8 X 3 = 24
5 | 8 X 4 = 32
6 | 8 X 5 = 40
7 | 8 X 6 = 48
8 | 8 X 7 = 56
9 | 8 X 8 = 64
10 | 8 X 9 = 72
11 | 8 X 10 = 80
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_9.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 9 is Written below:
2 | 9 X 1 = 9
3 | 9 X 2 = 18
4 | 9 X 3 = 27
5 | 9 X 4 = 36
6 | 9 X 5 = 45
7 | 9 X 6 = 54
8 | 9 X 7 = 63
9 | 9 X 8 = 72
10 | 9 X 9 = 81
11 | 9 X 10 = 90
12 |
--------------------------------------------------------------------------------
/problems/factorial_trailing_zeroes/solution.py:
--------------------------------------------------------------------------------
1 | import math
2 | class Solution:
3 | def trailingZeroes(self, n: int) -> int:
4 | ans = 0
5 | while n != 0:
6 | n //= 5
7 | ans += n
8 |
9 | return ans
--------------------------------------------------------------------------------
/problems/fair_candy_swap/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def fairCandySwap(self, A, B):
3 | dif = (sum(A) - sum(B)) / 2
4 | A = set(A)
5 | for b in set(B):
6 | if dif + b in A:
7 | return [dif + b, b]
--------------------------------------------------------------------------------
/problems/power_of_two/solution.py:
--------------------------------------------------------------------------------
1 | import math
2 | class Solution:
3 | def isPowerOfTwo(self, n: int) -> bool:
4 | if n <= 0: return False
5 |
6 | a = math.log(n) / math.log(2)
7 | a = round(a)
8 | return 2**a == n
--------------------------------------------------------------------------------
/problems/shuffle_string/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def restoreString(self, s: str, indices: List[int]) -> str:
3 | ans = [0]*len(s)
4 | for i in range(len(ans)):
5 | ans[indices[i]] = s[i]
6 | return ''.join(ans)
--------------------------------------------------------------------------------
/1141-user-activity-for-the-past-30-days-i/1141-user-activity-for-the-past-30-days-i.sql:
--------------------------------------------------------------------------------
1 | select activity_date as day, count(distinct user_id) as active_users from activity where activity_date > '2019-06-27' and activity_date <= '2019-07-27' group by activity_date;
--------------------------------------------------------------------------------
/136-single-number/136-single-number.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def singleNumber(self, nums: List[int]) -> int:
3 | res = nums[0]
4 |
5 | for i in range(1, len(nums)):
6 | res = res ^ nums[i]
7 |
8 | return res
--------------------------------------------------------------------------------
/168_Excel_Sheet_Column_Title.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def convertToTitle(self, n: int) -> str:
3 | res = ""
4 | while n > 0:
5 | n -= 1
6 | res = chr(65 + n % 26) + res
7 | n //= 26
8 | return res
9 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/LexycoGrafic Operators Order (copy):
--------------------------------------------------------------------------------
1 | a = 10>4
2 | print(a)
3 | a = "abc" >"yz"
4 | print(a)
5 | a = "abc" >"ABC"
6 | print(a)
7 | a = ord("A")
8 | print(a)
9 | a = ord("a")
10 | print(a)
11 | a = ord("x")
12 | print(a)
13 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/__init__() constructor (copy):
--------------------------------------------------------------------------------
1 | class Employee:
2 | def __init__(self,name):
3 | self.name = name
4 | def getSalary(self):
5 | #Some code…
6 | harry = Employee(“Harry”) #Object can be instantiated using constructor like this!
7 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/log.txt:
--------------------------------------------------------------------------------
1 | PyThOn
2 | Samir
3 | I am The Best
4 | best course to learn programming
5 | Thanks
6 | PytHoN
7 | vmaekeraa
8 | emwkfm krrrrrrrrrr kkkkee mrknq qjhijv orhrv riuqogj oijog
9 | vvkgn pYthoN knejfwn
10 |
--------------------------------------------------------------------------------
/problems/fibonacci_number/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def fib(self, n: int) -> int:
3 | if n == 0:
4 | return 0
5 | elif n == 1:
6 | return 1
7 | else:
8 | return self.fib(n-1) + self.fib(n-2)
--------------------------------------------------------------------------------
/0461-hamming-distance/0461-hamming-distance.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def hammingDistance(self, x: int, y: int) -> int:
3 | res = 0
4 | for i in range(32):
5 | if x&(1< bool:
3 | return s == target or (int(s) > 0 and int(target) > 0)
4 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/If, elif, else. (copy):
--------------------------------------------------------------------------------
1 | a = 2
2 | if a>0 :
3 | print("Positive")
4 | elif a==-5:
5 | print("-Five")
6 | elif a ==0:
7 | print("Zero")
8 | elif a ==-2:
9 | print("-Two")
10 | else:
11 | print("Negative")
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/New_File.txt:
--------------------------------------------------------------------------------
1 | PyThOn
2 | Samir
3 | I am The Best
4 | best course to learn programming
5 | Thanks
6 | PytHoN
7 | vmaekeraa
8 | emwkfm krrrrrrrrrr kkkkee mrknq qjhijv orhrv riuqogj oijog
9 | vvkgn pYthoN knejfwn
10 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/samir.py:
--------------------------------------------------------------------------------
1 | import os
2 | oldname = "siliguri.txt"
3 | newname = "New_File.txt"
4 | with open('siliguri.txt','r') as f:
5 | a = f.read()
6 |
7 | with open('New_File.txt','w') as f:
8 | f.write(a)
9 |
10 | os.remove(oldname)
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/this.txt:
--------------------------------------------------------------------------------
1 | PyThOn
2 | Samir
3 | I am The Best
4 | best course to learn programming
5 | Thanks
6 | PytHoN
7 | vmaekeraa
8 | emwkfm krrrrrrrrrr kkkkee mrknq qjhijv orhrv riuqogj oijog
9 | vvkgn pYthoN knejfwn
10 |
--------------------------------------------------------------------------------
/problems/maximum_product_of_two_elements_in_an_array/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def maxProduct(self, nums: List[int]) -> int:
3 | nums.sort()
4 | a = (nums[-1]-1)*(nums[-2]-1)
5 | b = (nums[0]-1)*(nums[1]-1)
6 | return max(a, b)
--------------------------------------------------------------------------------
/0189-rotate-array/0189-rotate-array.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def rotate(self, nums: List[int], k: int) -> None:
3 | k = k % len(nums)
4 | nums.reverse()
5 | nums[:k] = nums[:k][::-1]
6 | nums[k:] = nums[k:][::-1]
7 | return nums
--------------------------------------------------------------------------------
/1587-bank-account-summary-ii/1587-bank-account-summary-ii.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select u.name, sum(t.amount) as balance
3 | from users as u left join transactions as t
4 | on u.account = t.account
5 | group by u.account having balance > 10000;
--------------------------------------------------------------------------------
/172-factorial-trailing-zeroes/172-factorial-trailing-zeroes.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def trailingZeroes(self, n: int) -> int:
3 | res = 0
4 |
5 | while n > 0:
6 | n = n// 5
7 | res += n
8 |
9 | return res
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/pattern.py:
--------------------------------------------------------------------------------
1 | '''
2 | *
3 | ***
4 | *****
5 | *******
6 | '''
7 | n = 4
8 | for i in range(n):
9 | print(" "*(n-i-1), end="")
10 | print("*"*(2*i +1), end="")
11 | print(" "*(n-i-1))
12 |
13 |
14 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/05_try_except_finally.py:
--------------------------------------------------------------------------------
1 | try:
2 | i = int(input("Enter a number: "))
3 | c = 1/i
4 | except Exception as e:
5 | print(e)
6 | exit()
7 | finally:
8 | print("We are done")
9 |
10 | print("Thanks for using the program")
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/24Dictionary of Hindi to English.py:
--------------------------------------------------------------------------------
1 | myDict = {
2 | "per":"Tree",
3 | "insan": "human",
4 | "kitab":"book",
5 | "pila":"yellow"
6 | }
7 | a = input("Write the word here:\n ")
8 | print("The meaning of the word is: ",myDict[a])
9 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_10.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 10 is Written below:
2 | 10 X 1 = 10
3 | 10 X 2 = 20
4 | 10 X 3 = 30
5 | 10 X 4 = 40
6 | 10 X 5 = 50
7 | 10 X 6 = 60
8 | 10 X 7 = 70
9 | 10 X 8 = 80
10 | 10 X 9 = 90
11 | 10 X 10 = 100
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_11.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 11 is Written below:
2 | 11 X 1 = 11
3 | 11 X 2 = 22
4 | 11 X 3 = 33
5 | 11 X 4 = 44
6 | 11 X 5 = 55
7 | 11 X 6 = 66
8 | 11 X 7 = 77
9 | 11 X 8 = 88
10 | 11 X 9 = 99
11 | 11 X 10 = 110
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_12.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 12 is Written below:
2 | 12 X 1 = 12
3 | 12 X 2 = 24
4 | 12 X 3 = 36
5 | 12 X 4 = 48
6 | 12 X 5 = 60
7 | 12 X 6 = 72
8 | 12 X 7 = 84
9 | 12 X 8 = 96
10 | 12 X 9 = 108
11 | 12 X 10 = 120
12 |
--------------------------------------------------------------------------------
/1407-top-travellers/1407-top-travellers.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select u.name, ifnull(sum(r.distance), 0) as travelled_distance
3 | from users as u left join rides as r on u.id = r.user_id
4 | group by u.id
5 | order by travelled_distance desc, name asc
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/05_try_except_finally (copy).py:
--------------------------------------------------------------------------------
1 | try:
2 | i = int(input("Enter a number: "))
3 | c = 1/i
4 | except Exception as e:
5 | print(e)
6 | exit()
7 | finally:
8 | print("We are done")
9 |
10 | print("Thanks for using the program")
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_13.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 13 is Written below:
2 | 13 X 1 = 13
3 | 13 X 2 = 26
4 | 13 X 3 = 39
5 | 13 X 4 = 52
6 | 13 X 5 = 65
7 | 13 X 6 = 78
8 | 13 X 7 = 91
9 | 13 X 8 = 104
10 | 13 X 9 = 117
11 | 13 X 10 = 130
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_14.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 14 is Written below:
2 | 14 X 1 = 14
3 | 14 X 2 = 28
4 | 14 X 3 = 42
5 | 14 X 4 = 56
6 | 14 X 5 = 70
7 | 14 X 6 = 84
8 | 14 X 7 = 98
9 | 14 X 8 = 112
10 | 14 X 9 = 126
11 | 14 X 10 = 140
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_15.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 15 is Written below:
2 | 15 X 1 = 15
3 | 15 X 2 = 30
4 | 15 X 3 = 45
5 | 15 X 4 = 60
6 | 15 X 5 = 75
7 | 15 X 6 = 90
8 | 15 X 7 = 105
9 | 15 X 8 = 120
10 | 15 X 9 = 135
11 | 15 X 10 = 150
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_16.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 16 is Written below:
2 | 16 X 1 = 16
3 | 16 X 2 = 32
4 | 16 X 3 = 48
5 | 16 X 4 = 64
6 | 16 X 5 = 80
7 | 16 X 6 = 96
8 | 16 X 7 = 112
9 | 16 X 8 = 128
10 | 16 X 9 = 144
11 | 16 X 10 = 160
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_17.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 17 is Written below:
2 | 17 X 1 = 17
3 | 17 X 2 = 34
4 | 17 X 3 = 51
5 | 17 X 4 = 68
6 | 17 X 5 = 85
7 | 17 X 6 = 102
8 | 17 X 7 = 119
9 | 17 X 8 = 136
10 | 17 X 9 = 153
11 | 17 X 10 = 170
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_18.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 18 is Written below:
2 | 18 X 1 = 18
3 | 18 X 2 = 36
4 | 18 X 3 = 54
5 | 18 X 4 = 72
6 | 18 X 5 = 90
7 | 18 X 6 = 108
8 | 18 X 7 = 126
9 | 18 X 8 = 144
10 | 18 X 9 = 162
11 | 18 X 10 = 180
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_19.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 19 is Written below:
2 | 19 X 1 = 19
3 | 19 X 2 = 38
4 | 19 X 3 = 57
5 | 19 X 4 = 76
6 | 19 X 5 = 95
7 | 19 X 6 = 114
8 | 19 X 7 = 133
9 | 19 X 8 = 152
10 | 19 X 9 = 171
11 | 19 X 10 = 190
12 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/table_of_20.txt:
--------------------------------------------------------------------------------
1 | The Multiplication Table of 20 is Written below:
2 | 20 X 1 = 20
3 | 20 X 2 = 40
4 | 20 X 3 = 60
5 | 20 X 4 = 80
6 | 20 X 5 = 100
7 | 20 X 6 = 120
8 | 20 X 7 = 140
9 | 20 X 8 = 160
10 | 20 X 9 = 180
11 | 20 X 10 = 200
12 |
--------------------------------------------------------------------------------
/leetcode-cpp/power-of-four/power-of-four.cpp:
--------------------------------------------------------------------------------
1 | class Solution {
2 | public:
3 | bool isPowerOfFour(int n) {
4 | for(int i=0;i<32;i+=2){
5 | if(n==(1< int:
3 | LL = []
4 | for i in range(len(accounts)):
5 | LL.append(sum(accounts[i]))
6 | return max(LL)
7 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/09_07_pr_03.py:
--------------------------------------------------------------------------------
1 |
2 | for i in range(2, 21):
3 | with open(f"tables/Multiplication_table_of_{i}.txt", 'w') as f:
4 | for j in range(1, 11):
5 | f.write(f"{i}X{j}={i*j}")
6 | if j!=10:
7 | f.write('\n')
8 |
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/file reading.py:
--------------------------------------------------------------------------------
1 |
2 | #f = open('text.txt', 'r')
3 | f = open('text.txt') # by default the mode si r that is read mode if it is a text file
4 | data = f.read()
5 | # data = f.read(10)
6 | print(data)
7 | f.close()
8 |
9 |
10 |
11 |
12 |
--------------------------------------------------------------------------------
/problems/find_numbers_with_even_number_of_digits/solution.py:
--------------------------------------------------------------------------------
1 | class Solution(object):
2 | def findNumbers(self, nums):
3 | """
4 | :type nums: List[int]
5 | :rtype: int
6 | """
7 | return len([num for num in nums if len(str(num))%2 == 0])
--------------------------------------------------------------------------------
/0027-remove-element/0027-remove-element.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def removeElement(self, nums: List[int], val: int) -> int:
3 | i = 0
4 | for num in nums:
5 | if num != val:
6 | nums[i] = num
7 | i += 1
8 | return i
--------------------------------------------------------------------------------
/problems/minimum_moves_to_equal_array_elements_ii/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def minMoves2(self, nums: List[int]) -> int:
3 | nums.sort()
4 | ans, median = 0, nums[len(nums) // 2]
5 | for num in nums: ans += abs(median - num)
6 | return ans
7 |
--------------------------------------------------------------------------------
/1050-actors-and-directors-who-cooperated-at-least-three-times/1050-actors-and-directors-who-cooperated-at-least-three-times.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select actor_id, director_id
3 | from ActorDirector group by actor_id, director_id
4 | having count(timestamp) >= 3;
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter1.py/09_pr_05.py:
--------------------------------------------------------------------------------
1 | names = ["harry", "shubham", "rohit", "rohan", "aditi", "shipra"]
2 | name = input("Enter the name to check\n")
3 |
4 | if name in names:
5 | print("Your name is present in the list")
6 | else:
7 | print("Your name is not present in the list")
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/inch to cm.py:
--------------------------------------------------------------------------------
1 | '''
2 | n =10
3 | def countup(n):
4 | if n >= 0:
5 | countup(n - 1)
6 | print(n)
7 |
8 | '''
9 |
10 | n = int(input("Type a number in inch here: "))
11 | def cem(n):
12 | return n*2.54
13 | print(cem(n))
14 |
15 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/08_global.py:
--------------------------------------------------------------------------------
1 | a = 54 # Global variable
2 | def func1():
3 | global a
4 | print(f"Print statement 1: {a}")
5 | a = 8 # Local Variable if global keyword is not used
6 | print(f"Print statement 2: {a}")
7 |
8 | func1()
9 | print(f"Print statement 3: {a}")
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/09_pr_05.py:
--------------------------------------------------------------------------------
1 | names = ["harry", "shubham", "rohit", "rohan", "aditi", "shipra"]
2 | name = input("Enter the name to check\n")
3 |
4 | if name in names:
5 | print("Your name is present in the list")
6 | else:
7 | print("Your name is not present in the list")
--------------------------------------------------------------------------------
/Basics-of-Python/Queue Data-Stracture/07.py:
--------------------------------------------------------------------------------
1 | class BST:
2 | def __init__(self,key):
3 | self.key = key
4 | self.lchild = None
5 | self.rchild = None
6 |
7 | root = BST(10)
8 | print(root.key)
9 | print(root.lchild)
10 | print(root.rchild)
11 |
12 |
13 |
--------------------------------------------------------------------------------
/problems/squares_of_a_sorted_array/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def sortedSquares(self, nums: List[int]) -> List[int]:
3 | for i in range(len(nums)):
4 | nums[i] = (nums[i]) **2
5 |
6 | print(nums)
7 | nums.sort()
8 | return nums
--------------------------------------------------------------------------------
/problems/truncate_sentence/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def truncateSentence(self, s: str, k: int) -> str:
3 | a = s.split()
4 | result = ""
5 | for i in range(k):
6 | result = result + a[i] + " "
7 |
8 | return result.rstrip(" ")
--------------------------------------------------------------------------------
/0053-maximum-subarray/0053-maximum-subarray.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def maxSubArray(self, nums: List[int]) -> int:
3 | cs = 0
4 | ms = nums[0]
5 | for num in nums:
6 | cs = max(cs+num, num)
7 | ms = max(ms, cs)
8 |
9 | return ms
--------------------------------------------------------------------------------
/1890-the-latest-login-in-2020/1890-the-latest-login-in-2020.sql:
--------------------------------------------------------------------------------
1 | SELECT
2 | user_id,
3 | MAX(time_stamp) AS last_stamp #obtaining latest login for all users
4 | FROM Logins
5 | WHERE YEAR(time_stamp) = 2020 #filtering for login dates with year 2020 in timestamp
6 | GROUP BY user_id;
7 |
--------------------------------------------------------------------------------
/problems/array_partition/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def arrayPairSum(self, nums: List[int]) -> int:
3 | nums.sort()
4 | ans = 0
5 | i = 0
6 | while i < len(nums)-1:
7 | ans += min(nums[i], nums[i+1])
8 | i += 2
9 | return ans
--------------------------------------------------------------------------------
/0176-second-highest-salary/0176-second-highest-salary.sql:
--------------------------------------------------------------------------------
1 | # select max(salary) as "SecondHighestSalary" from employee where salary not in (select max(salary) from employee);
2 |
3 | select (select distinct salary from employee order by salary desc limit 1 offset 1) as SecondHighestSalary;
4 |
5 |
--------------------------------------------------------------------------------
/0462-minimum-moves-to-equal-array-elements-ii/0462-minimum-moves-to-equal-array-elements-ii.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def minMoves2(self, nums: List[int]) -> int:
3 | nums.sort()
4 | n = len(nums)
5 | mid = n//2
6 | return sum(abs(nums[i] - nums[mid]) for i in range(n))
--------------------------------------------------------------------------------
/349_Intersection_of_Two_Arrays.py:
--------------------------------------------------------------------------------
1 | class Solution(object):
2 | def intersection(self, nums1, nums2):
3 | """
4 | :type nums1: List[int]
5 | :type nums2: List[int]
6 | :rtype: List[int]
7 | """
8 | # set
9 | return list(set(nums1) & set(nums2))
--------------------------------------------------------------------------------
/771-jewels-and-stones/771-jewels-and-stones.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def numJewelsInStones(self, jewels: str, stones: str) -> int:
3 | jewels = set(jewels)
4 | res = 0
5 |
6 | for s in stones:
7 | if s in jewels: res += 1
8 |
9 | return res
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/06_self.py:
--------------------------------------------------------------------------------
1 | class Employee:
2 | company = "Google"
3 | def getSalary(self):
4 | print(f"Salary for this employee working in {self.company} is {self.salary}")
5 |
6 | harry = Employee()
7 | harry.salary = 100000
8 | harry.getSalary() # Employee.getSalary(harry)
--------------------------------------------------------------------------------
/problems/find_the_highest_altitude/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def largestAltitude(self, gain: List[int]) -> int:
3 | s = 0
4 | L = [0]
5 | for i in range(len(gain)):
6 | s = s+ gain[i]
7 | L.append(s)
8 | return max(L)
9 |
--------------------------------------------------------------------------------
/0586-customer-placing-the-largest-number-of-orders/0586-customer-placing-the-largest-number-of-orders.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select customer_number from (select customer_number from orders group by customer_number order by count(customer_number) desc) as customer_number limit 1;
--------------------------------------------------------------------------------
/0746-min-cost-climbing-stairs/0746-min-cost-climbing-stairs.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def minCostClimbingStairs(self, cost: List[int]) -> int:
3 | cost += [0]
4 | for i in range(2, len(cost)):
5 | cost[i] += min(cost[i-1], cost[i-2])
6 | return min(cost[-1], cost[-2])
--------------------------------------------------------------------------------
/1158-market-analysis-i/1158-market-analysis-i.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select u.user_id as buyer_id, u.join_date, ifnull(count(order_date), 0) as orders_in_2019
3 | from users as u left join orders as o on year(order_date) = '2019' and u.user_id = o.buyer_id
4 | group by user_id;
--------------------------------------------------------------------------------
/1693-daily-leads-and-partners/1693-daily-leads-and-partners.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | SELECT
3 | date_id, make_name,
4 | COUNT(DISTINCT lead_id) AS unique_leads,
5 | COUNT(DISTINCT partner_id) AS unique_partners
6 | FROM DailySales
7 | GROUP BY make_name, date_id
--------------------------------------------------------------------------------
/1844-replace-all-digits-with-characters/1844-replace-all-digits-with-characters.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def replaceDigits(self, s: str) -> str:
3 | s = list(s)
4 | for i in range(1, len(s), 2):
5 | s[i] = chr(ord(s[i-1]) + int(s[i]))
6 |
7 | return "".join(s)
--------------------------------------------------------------------------------
/392-is-subsequence/392-is-subsequence.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def isSubsequence(self, s: str, t: str) -> bool:
3 | stack = list(s[::-1])
4 |
5 | for i in t:
6 | if stack and stack[-1] == i:
7 | stack.pop()
8 |
9 | return len(stack) == 0
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/name-greetings-by-for-loop-and-if-else.py:
--------------------------------------------------------------------------------
1 | l1 = ["Samir Paul","Rohan","Sumit Bagchi","Rahul","Swapan kumar paul","Aniket Samanta"]
2 |
3 | for name in l1:
4 | name.capitalize()
5 | if name.startswith("S"):
6 | print("Hello \t"+ name + " You are selected")
7 |
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/09_09_pr_05.py:
--------------------------------------------------------------------------------
1 | words = ["donkey", "kaddu", "mote"]
2 |
3 | with open("sample.txt") as f:
4 | content = f.read()
5 |
6 |
7 | for word in words:
8 | content = content.replace(word, "$%^@$^#")
9 | with open("sample.txt", "w") as f:
10 | f.write(content)
--------------------------------------------------------------------------------
/Basics-of-Python/Practice/21.py:
--------------------------------------------------------------------------------
1 | a = set()
2 | a.add(3)
3 | a.add(4)
4 | a.add(5)
5 | a.add(6)
6 | a.add(10)
7 | # a.add((2,3,4,5,,6,7)) # can not add a tuple to a set
8 | # a.add({2,3,4,5,6,7}) # can not add to a set >> unhasheble
9 | # a.add([1,2,3,4,5,6,7,8]) # can not add
10 | print(a)
11 |
--------------------------------------------------------------------------------
/problems/egg_drop_with_2_eggs_and_n_floors/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def twoEggDrop(self, n: int) -> int:
3 | c = 0
4 | i = 0
5 | while i < n:
6 | c += 1
7 | i += c
8 | return c
9 |
10 |
11 |
--------------------------------------------------------------------------------
/problems/kth_smallest_element_in_a_sorted_matrix/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def kthSmallest(self, matrix: List[List[int]], k: int) -> int:
3 | a = []
4 | for row in matrix:
5 | for i in row:
6 | a.append(i)
7 | a.sort()
8 | return a[k-1]
--------------------------------------------------------------------------------
/0196-delete-duplicate-emails/0196-delete-duplicate-emails.sql:
--------------------------------------------------------------------------------
1 | # Please write a DELETE statement and DO NOT write a SELECT statement.
2 | # Write your MySQL query statement below
3 |
4 |
5 | delete from Person where id not in
6 | (select * from (select min(id) from Person group by email) as p);
7 |
8 |
9 |
--------------------------------------------------------------------------------
/1484-group-sold-products-by-the-date/1484-group-sold-products-by-the-date.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select sell_date, count(distinct product) as num_sold, group_concat(distinct product order by product asc separator ',') as products from Activities group by sell_date order by sell_date asc;
--------------------------------------------------------------------------------
/1922-count-good-numbers/1922-count-good-numbers.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def countGoodNumbers(self, n: int) -> int:
3 | ans = 1
4 | rem = n % 2
5 | n -= rem
6 | ans = pow(20, n//2, 10**9 + 7)
7 | if rem == 1:
8 | ans *= 5
9 | return ans % (10**9 + 7)
--------------------------------------------------------------------------------
/1985-find-the-kth-largest-integer-in-the-array/1985-find-the-kth-largest-integer-in-the-array.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def kthLargestNumber(self, nums: List[str], k: int) -> str:
3 | for i, ch in enumerate(nums):
4 | nums[i] = int(ch)
5 | nums.sort()
6 | return str(nums[-k])
--------------------------------------------------------------------------------
/461-hamming-distance/461-hamming-distance.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def hammingDistance(self, x: int, y: int) -> int:
3 | a = x ^ y
4 | res = 0
5 |
6 | for i in range(32):
7 | res += a & 1
8 | a = a >> 1
9 |
10 | return res
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/001Conditional_statement_in_python.py:
--------------------------------------------------------------------------------
1 | a = [2,3,4,6,9,23,94,1,353,242,45,24]
2 |
3 | b = set()
4 | c = set()
5 |
6 |
7 | for i in range(0,len(a)):
8 | if(a[i]>10):
9 | b.add(a[i])
10 | else:
11 | c.add(a[i])
12 |
13 | print(b)
14 | print(c)
15 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/Sum of first n natual number using for loop.py:
--------------------------------------------------------------------------------
1 | n = int(input("Type a Natural number: \n"))
2 | i = 1
3 | if n>0:
4 | sum = 0
5 | for i in range(1,n+1):
6 | sum = sum + i
7 | print(sum)
8 | else:
9 | print("Type Natural numbers only")
10 |
11 |
--------------------------------------------------------------------------------
/problems/reverse_string/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def reverseString(self, s: List[str]) -> None:
3 | def rev(l, r, s):
4 | if l >= r: return
5 | s[l], s[r] = s[r], s[l]
6 | rev(l+1, r-1, s)
7 |
8 | return rev(0, len(s)-1, s)
9 |
--------------------------------------------------------------------------------
/problems/sort_colors/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def sortColors(self, nums: List[int]) -> None:
3 | for i in range(len(nums)-1):
4 | for j in range(len(nums)-1):
5 | if nums[j]>nums[j+1]:
6 | nums[j], nums[j+1] = nums[j+1], nums[j]
7 |
--------------------------------------------------------------------------------
/problems/sum_of_digits_in_base_k/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def sumBase(self, n: int, k: int) -> int:
3 | sum = 0
4 | if n >= 1 and n<= 100 and k>= 2 and k<= 10:
5 | while n != 0:
6 | sum = sum + n%k
7 | n = n//k
8 | return sum
9 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/Identifing a spam commet from many words.py:
--------------------------------------------------------------------------------
1 | spam_comments = ["spam","bad","Worst","Not Good","lazy","dog","cat","false"]
2 |
3 | a = input("Write a comment here: \n")
4 |
5 | if(a in spam_comments):
6 | print("It Is A SPAM COMMENT")
7 | else:
8 | print("Good commemt")
9 |
--------------------------------------------------------------------------------
/problems/shuffle_the_array/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def shuffle(self, nums: List[int], n: int) -> List[int]:
3 | newL = []
4 | if len(nums) == 2*n:
5 | for i in range(n):
6 | newL.append(nums[i])
7 | newL.append(nums[n+i])
8 | return newL
--------------------------------------------------------------------------------
/0263-ugly-number/0263-ugly-number.py:
--------------------------------------------------------------------------------
1 | # https://youtu.be/M0Zay1Qr9ws
2 |
3 | class Solution:
4 | def isUgly(self, n: int) -> bool:
5 | if n <= 0: return False
6 | for p in [2, 3, 5]:
7 | while n % p == 0:
8 | n = n // p
9 |
10 | return n == 1
--------------------------------------------------------------------------------
/121-best-time-to-buy-and-sell-stock/121-best-time-to-buy-and-sell-stock.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def maxProfit(self, prices: List[int]) -> int:
3 | res = 0
4 | mini = prices[0]
5 | for i in prices:
6 | mini = min(i, mini)
7 | res = max(res, i-mini)
8 | return res
--------------------------------------------------------------------------------
/137-single-number-ii/137-single-number-ii.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def singleNumber(self, nums: List[int]) -> int:
3 | ones = 0; twos = 0
4 |
5 | for num in nums:
6 | ones = (ones ^ num) & (~ twos)
7 | twos = (twos ^ num) & (~ ones)
8 |
9 | return ones
--------------------------------------------------------------------------------
/231_Power_of_Two.py:
--------------------------------------------------------------------------------
1 | class Solution(object):
2 | def isPowerOfTwo(self, n):
3 | """
4 | :type n: int
5 | :rtype: bool
6 | """
7 | if n < 0:
8 | return False
9 | bin_str = bin(n)
10 | return sum(map(lambda x: int(x), list(bin_str[2:]))) == 1
--------------------------------------------------------------------------------
/961-n-repeated-element-in-size-2n-array/961-n-repeated-element-in-size-2n-array.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def repeatedNTimes(self, nums: List[int]) -> int:
3 | seen = set()
4 | for i in nums:
5 | if i in seen: return i
6 | else:
7 | seen.add(i)
8 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/02.py:
--------------------------------------------------------------------------------
1 | '''
2 | a = True
3 | b = None
4 | print(type(a))
5 | print(type(b))
6 | '''
7 | a = 3
8 | b = 4
9 | print("The value of 3+4 is ",3+4)
10 | print("The value of 3-4 is ", 3-4)
11 |
12 | a +=20
13 | a -=30
14 | a *=45
15 | a /=39
16 | print("The final value of a is ",a)
17 |
--------------------------------------------------------------------------------
/Basics-of-Python/Chapter2.py/else_optional.py:
--------------------------------------------------------------------------------
1 | a =-332
2 | if(a==7):
3 | print("fanfkjnfkjfn")
4 | elif(a>24):
5 | print("NNNNNNNND")
6 | elif(a<23):
7 | print("WWWWWWWWWw")
8 | elif(a==0):
9 | print("SSSSSSSSSSSSSSSsssSSSSSSss")
10 | #else:
11 | # print("____------____")
--------------------------------------------------------------------------------
/Basics-of-Python/chapter3 .py/rewrite_bad_words_from_a_file.py:
--------------------------------------------------------------------------------
1 | words = ['donkey','kaddu','bad','worst','mote']
2 |
3 | with open('comment.txt','r') as f:
4 | a = f.read()
5 |
6 | for word in words:
7 | a = a.replace(word,"@#$%@")
8 | with open('comment.txt','w') as f:
9 | f.write(a)
10 |
--------------------------------------------------------------------------------
/problems/valid_palindrome/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def isPalindrome(self, s: str) -> bool:
3 | a = ""
4 | for i in s:
5 | if ord("A")<= ord(i)<= ord("Z") or ord("a")<= ord(i)<= ord("z") or ord("0")<= ord(i)<= ord("9"):
6 | a += i.lower()
7 | return a == a[::-1]
--------------------------------------------------------------------------------
/0096-unique-binary-search-trees/0096-unique-binary-search-trees.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def numTrees(self, n: int) -> int:
3 | dp = [0]*(n+1)
4 | dp[0] = 1
5 | for i in range(1, n+1):
6 | for j in range(i):
7 | dp[i] += dp[j]*dp[i-j-1]
8 |
9 | return dp[n]
--------------------------------------------------------------------------------
/0121-best-time-to-buy-and-sell-stock/0121-best-time-to-buy-and-sell-stock.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def maxProfit(self, prices: List[int]) -> int:
3 | res = 0
4 | mini = prices[0]
5 | for p in prices[1:]:
6 | res = max(res, p - mini)
7 | mini = min(mini, p)
8 | return res
--------------------------------------------------------------------------------
/258_Add_Digits.py:
--------------------------------------------------------------------------------
1 | class Solution(object):
2 | def addDigits(self, num):
3 | """
4 | :type num: int
5 | :rtype: int
6 | """
7 | # https: // en.wikipedia.org / wiki / Digital_root
8 | if num < 10:
9 | return num
10 | return num - ((num - 1) / 9) * 9
--------------------------------------------------------------------------------
/Basics-of-Python/Queue Data-Stracture/05.py:
--------------------------------------------------------------------------------
1 | n = ["a","b","a","b","a","a"]
2 | l = len(n)
3 |
4 | m = []
5 |
6 | i = 0
7 | for i in range(int(l/2)):
8 | m.append(n[int(l/2) + i])
9 |
10 | j = 0
11 | for j in range(int(l/2)):
12 | m.append(n[j])
13 |
14 | print(m) # ['b', 'a', 'a', 'a', 'b', 'a']
15 |
16 |
--------------------------------------------------------------------------------
/leetcode-cpp/department-highest-salary/department-highest-salary.sql:
--------------------------------------------------------------------------------
1 | # Write your MySQL query statement below
2 | select d.name as 'Department',E.NAME AS 'Employee',e.salary
3 | from department d,employee e
4 | where d.id = e.departmentId
5 | and e.salary = (select max(e1.salary) from employee e1 where e1.departmentId = d.id)
--------------------------------------------------------------------------------
/leetcode-cpp/reverse-bits/reverse-bits.cpp:
--------------------------------------------------------------------------------
1 | class Solution {
2 | public:
3 | uint32_t reverseBits(uint32_t n) {
4 | uint32_t ans=0, pow=31;
5 | while(n!=0){
6 | ans+=(n&1)<>1;
8 | pow-=1;
9 | }
10 | return ans;
11 | }
12 | };
13 |
--------------------------------------------------------------------------------
/problems/best_time_to_buy_and_sell_stock_ii/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def maxProfit(self, prices: List[int]) -> int:
3 | res = 0
4 | for i in range(len(prices) - 1):
5 | if prices[i + 1] > prices[i]:
6 | res += prices[i + 1] - prices[i]
7 |
8 | return res
--------------------------------------------------------------------------------
/problems/goal_parser_interpretation/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def interpret(self, command: str) -> str:
3 | if len(command) <=100 and len(command)>=1:
4 | command = command.replace("()","o")
5 | command = command.replace("(al)", "al")
6 |
7 | return command
8 |
--------------------------------------------------------------------------------
/problems/running_sum_of_1d_array/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def runningSum(self, nums: List[int]) -> List[int]:
3 | runningSum = []
4 | Sum = 0
5 | for i in range(len(nums)):
6 | Sum += nums[i]
7 | runningSum.append(Sum)
8 | return runningSum
9 |
--------------------------------------------------------------------------------
/problems/unique_paths/solution.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def uniquePaths(self, m: int, n: int) -> int:
3 | dp = [[1]*n for i in range(m)]
4 |
5 | for i in range(1, m):
6 | for j in range(1, n):
7 | dp[i][j] = dp[i-1][j] + dp[i][j-1]
8 |
9 | return dp[-1][-1]
--------------------------------------------------------------------------------
/0001-two-sum/0001-two-sum.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def twoSum(self, nums: List[int], target: int) -> List[int]:
3 | taken = {}
4 | for i, num in enumerate(nums):
5 | if target - num in taken:
6 | return [taken[target - num], i]
7 | taken[num] = i
8 | return False
--------------------------------------------------------------------------------
/1-two-sum/1-two-sum.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def twoSum(self, nums: List[int], target: int) -> List[int]:
3 | dic = {}
4 | for i, ch in enumerate(nums):
5 | n = target - ch
6 | if n in dic:
7 | return [dic[n], i]
8 | dic[ch] = i
9 |
10 |
--------------------------------------------------------------------------------
/119-pascals-triangle-ii/119-pascals-triangle-ii.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def getRow(self, rowIndex: int) -> List[int]:
3 | arr = [1] * (rowIndex+1)
4 |
5 | for i in range(2, rowIndex+1):
6 | for j in range(i-1, 0, -1):
7 | arr[j] += arr[j-1]
8 |
9 | return arr
--------------------------------------------------------------------------------
/179_Largest_Number.py:
--------------------------------------------------------------------------------
1 | class LargerNumKey(str):
2 | def __lt__(x, y):
3 | return x + y > y + x
4 |
5 |
6 | class Solution:
7 | def largestNumber(self, nums):
8 | largest_num = ''.join(sorted(map(str, nums), key=LargerNumKey))
9 | return '0' if largest_num[0] == '0' else largest_num
10 |
--------------------------------------------------------------------------------
/62-unique-paths/62-unique-paths.py:
--------------------------------------------------------------------------------
1 | class Solution:
2 | def uniquePaths(self, m: int, n: int) -> int:
3 | dp = [[1]*n for i in range(m)]
4 |
5 | for i in range(1, m):
6 | for j in range(1, n):
7 | dp[i][j] = dp[i-1][j] + dp[i][j-1]
8 |
9 | return dp[-1][-1]
--------------------------------------------------------------------------------