leetcode-py-sdk 0.44.0__tar.gz → 0.46.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (232) hide show
  1. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/PKG-INFO +2 -2
  2. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/README.md +1 -1
  3. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/pyproject.toml +1 -1
  4. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/best_time_to_buy_and_sell_stock_with_cooldown.json +89 -0
  5. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/burst_balloons.json +89 -0
  6. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/car_fleet.json +91 -0
  7. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/coin_change_ii.json +92 -0
  8. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/copy_list_with_random_pointer.json +91 -0
  9. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/count_good_nodes_in_binary_tree.json +95 -0
  10. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/design_twitter.json +99 -0
  11. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/detect_squares.json +90 -0
  12. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/distinct_subsequences.json +90 -0
  13. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/edit_distance.json +89 -0
  14. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/hand_of_straights.json +88 -0
  15. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/happy_number.json +89 -0
  16. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/interleaving_string.json +96 -0
  17. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/koko_eating_bananas.json +91 -0
  18. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/kth_largest_element_in_a_stream.json +87 -0
  19. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/kth_largest_element_in_an_array.json +89 -0
  20. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/last_stone_weight.json +84 -0
  21. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/max_area_of_island.json +88 -0
  22. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/merge_triplets_to_form_target_triplet.json +93 -0
  23. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/min_cost_climbing_stairs.json +88 -0
  24. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/minimum_interval_to_include_each_query.json +89 -0
  25. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/n_queens.json +90 -0
  26. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/network_delay_time.json +91 -0
  27. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/partition_labels.json +88 -0
  28. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/plus_one.json +92 -0
  29. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/reconstruct_itinerary.json +89 -0
  30. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/redundant_connection.json +87 -0
  31. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/search_a_2d_matrix.json +91 -0
  32. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/single_number.json +91 -0
  33. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/subsets_ii.json +88 -0
  34. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/surrounded_regions.json +89 -0
  35. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/swim_in_rising_water.json +88 -0
  36. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/target_sum.json +89 -0
  37. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/two_sum_ii_input_array_is_sorted.json +92 -0
  38. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/valid_parenthesis_string.json +92 -0
  39. leetcode_py_sdk-0.46.0/src/leetcode_py/cli/resources/leetcode/json/problems/walls_and_gates.json +92 -0
  40. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/tags.json5 +36 -0
  41. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/__init__.py +0 -0
  42. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/__init__.py +0 -0
  43. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/commands/__init__.py +0 -0
  44. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/commands/gen.py +0 -0
  45. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/commands/list.py +0 -0
  46. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/commands/scrape.py +0 -0
  47. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/main.py +0 -0
  48. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/cookiecutter.json +0 -0
  49. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/accounts_merge.json +0 -0
  50. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/add_binary.json +0 -0
  51. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/add_two_numbers.json +0 -0
  52. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/alien_dictionary.json +0 -0
  53. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/balanced_binary_tree.json +0 -0
  54. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/basic_calculator.json +0 -0
  55. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/best_time_to_buy_and_sell_stock.json +0 -0
  56. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/binary_search.json +0 -0
  57. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/binary_tree_inorder_traversal.json +0 -0
  58. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/binary_tree_level_order_traversal.json +0 -0
  59. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/binary_tree_maximum_path_sum.json +0 -0
  60. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/binary_tree_postorder_traversal.json +0 -0
  61. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/binary_tree_preorder_traversal.json +0 -0
  62. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/binary_tree_right_side_view.json +0 -0
  63. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/cheapest_flights_within_k_stops.json +0 -0
  64. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/climbing_stairs.json +0 -0
  65. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/clone_graph.json +0 -0
  66. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/coin_change.json +0 -0
  67. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/combination_sum.json +0 -0
  68. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/combination_sum_ii.json +0 -0
  69. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/construct_binary_tree_from_preorder_and_inorder_traversal.json +0 -0
  70. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/container_with_most_water.json +0 -0
  71. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/contains_duplicate.json +0 -0
  72. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/contiguous_array.json +0 -0
  73. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/counting_bits.json +0 -0
  74. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/course_schedule.json +0 -0
  75. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/course_schedule_ii.json +0 -0
  76. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/daily_temperatures.json +0 -0
  77. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/decode_string.json +0 -0
  78. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/decode_ways.json +0 -0
  79. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/design_add_and_search_words_data_structure.json +0 -0
  80. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/design_in_memory_file_system.json +0 -0
  81. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/diagonal_traverse.json +0 -0
  82. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/diameter_of_binary_tree.json +0 -0
  83. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/encode_and_decode_strings.json +0 -0
  84. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/evaluate_reverse_polish_notation.json +0 -0
  85. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/find_all_anagrams_in_a_string.json +0 -0
  86. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/find_first_and_last_position_of_element_in_sorted_array.json +0 -0
  87. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/find_k_closest_elements.json +0 -0
  88. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/find_median_from_data_stream.json +0 -0
  89. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/find_minimum_in_rotated_sorted_array.json +0 -0
  90. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/find_the_duplicate_number.json +0 -0
  91. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/first_bad_version.json +0 -0
  92. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/first_missing_positive.json +0 -0
  93. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/flood_fill.json +0 -0
  94. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/gas_station.json +0 -0
  95. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/generate_parentheses.json +0 -0
  96. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/graph_valid_tree.json +0 -0
  97. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/group_anagrams.json +0 -0
  98. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/house_robber.json +0 -0
  99. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/house_robber_ii.json +0 -0
  100. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/implement_queue_using_stacks.json +0 -0
  101. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/implement_trie_prefix_tree.json +0 -0
  102. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/insert_interval.json +0 -0
  103. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/invert_binary_tree.json +0 -0
  104. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/is_graph_bipartite.json +0 -0
  105. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/is_subsequence.json +0 -0
  106. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/jump_game.json +0 -0
  107. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/jump_game_ii.json +0 -0
  108. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/k_closest_points_to_origin.json +0 -0
  109. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/kth_smallest_element_in_a_bst.json +0 -0
  110. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/largest_rectangle_in_histogram.json +0 -0
  111. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/letter_combinations_of_a_phone_number.json +0 -0
  112. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/linked_list_cycle.json +0 -0
  113. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/linked_list_cycle_ii.json +0 -0
  114. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/longest_common_subsequence.json +0 -0
  115. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/longest_consecutive_sequence.json +0 -0
  116. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/longest_increasing_path_in_a_matrix.json +0 -0
  117. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/longest_increasing_subsequence.json +0 -0
  118. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/longest_palindrome.json +0 -0
  119. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/longest_palindromic_substring.json +0 -0
  120. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/longest_repeating_character_replacement.json +0 -0
  121. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/longest_substring_without_repeating_characters.json +0 -0
  122. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/lowest_common_ancestor_of_a_binary_search_tree.json +0 -0
  123. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/lowest_common_ancestor_of_a_binary_tree.json +0 -0
  124. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/lru_cache.json +0 -0
  125. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/majority_element.json +0 -0
  126. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/max_points_on_a_line.json +0 -0
  127. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/maximum_depth_of_binary_tree.json +0 -0
  128. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/maximum_product_subarray.json +0 -0
  129. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/maximum_profit_in_job_scheduling.json +0 -0
  130. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/maximum_subarray.json +0 -0
  131. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/maximum_width_of_binary_tree.json +0 -0
  132. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/median_of_two_sorted_arrays.json +0 -0
  133. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/meeting_rooms.json +0 -0
  134. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/meeting_rooms_ii.json +0 -0
  135. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/merge_intervals.json +0 -0
  136. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/merge_k_sorted_lists.json +0 -0
  137. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/merge_two_sorted_lists.json +0 -0
  138. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/middle_of_the_linked_list.json +0 -0
  139. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/min_cost_to_connect_all_points.json +0 -0
  140. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/min_stack.json +0 -0
  141. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/minimum_height_trees.json +0 -0
  142. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/minimum_path_sum.json +0 -0
  143. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/minimum_window_substring.json +0 -0
  144. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/missing_number.json +0 -0
  145. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/multiply_strings.json +0 -0
  146. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/my_calendar_i.json +0 -0
  147. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/next_permutation.json +0 -0
  148. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/non_overlapping_intervals.json +0 -0
  149. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/number_of_1_bits.json +0 -0
  150. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/number_of_connected_components_in_an_undirected_graph.json +0 -0
  151. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/number_of_islands.json +0 -0
  152. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/number_of_provinces.json +0 -0
  153. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/odd_even_linked_list.json +0 -0
  154. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/pacific_atlantic_water_flow.json +0 -0
  155. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/palindrome_partitioning.json +0 -0
  156. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/palindromic_substrings.json +0 -0
  157. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/partition_equal_subset_sum.json +0 -0
  158. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/path_sum_ii.json +0 -0
  159. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/path_sum_iii.json +0 -0
  160. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/permutation_in_string.json +0 -0
  161. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/permutations.json +0 -0
  162. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/powx_n.json +0 -0
  163. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/product_of_array_except_self.json +0 -0
  164. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/ransom_note.json +0 -0
  165. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/regular_expression_matching.json +0 -0
  166. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/remove_nth_node_from_end_of_list.json +0 -0
  167. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/reorder_list.json +0 -0
  168. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/reverse_bits.json +0 -0
  169. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/reverse_integer.json +0 -0
  170. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/reverse_linked_list.json +0 -0
  171. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/reverse_linked_list_ii.json +0 -0
  172. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/reverse_nodes_in_k_group.json +0 -0
  173. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/reverse_words_in_a_string.json +0 -0
  174. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/rotate_array.json +0 -0
  175. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/rotate_image.json +0 -0
  176. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/rotting_oranges.json +0 -0
  177. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/same_tree.json +0 -0
  178. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/search_in_rotated_sorted_array.json +0 -0
  179. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/serialize_and_deserialize_binary_tree.json +0 -0
  180. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/set_matrix_zeroes.json +0 -0
  181. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/single_number_iii.json +0 -0
  182. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/sliding_window_maximum.json +0 -0
  183. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/sort_colors.json +0 -0
  184. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/spiral_matrix.json +0 -0
  185. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/string_to_integer_atoi.json +0 -0
  186. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/subarray_sum_equals_k.json +0 -0
  187. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/subsets.json +0 -0
  188. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/subtree_of_another_tree.json +0 -0
  189. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/sum_of_two_integers.json +0 -0
  190. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/swap_nodes_in_pairs.json +0 -0
  191. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/task_scheduler.json +0 -0
  192. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/three_sum.json +0 -0
  193. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/time_based_key_value_store.json +0 -0
  194. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/top_k_frequent_elements.json +0 -0
  195. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/top_k_frequent_words.json +0 -0
  196. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/trapping_rain_water.json +0 -0
  197. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/two_sum.json +0 -0
  198. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/unique_paths.json +0 -0
  199. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/valid_anagram.json +0 -0
  200. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/valid_palindrome.json +0 -0
  201. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/valid_parentheses.json +0 -0
  202. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/valid_sudoku.json +0 -0
  203. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/validate_binary_search_tree.json +0 -0
  204. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/word_break.json +0 -0
  205. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/word_ladder.json +0 -0
  206. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/word_search.json +0 -0
  207. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/word_search_ii.json +0 -0
  208. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/json/problems/zero_one_matrix.json +0 -0
  209. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/{{cookiecutter.problem_name}}/README.md +0 -0
  210. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/{{cookiecutter.problem_name}}/__init__.py +0 -0
  211. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/{{cookiecutter.problem_name}}/helpers.py +0 -0
  212. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/{{cookiecutter.problem_name}}/playground.ipynb +0 -0
  213. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/{{cookiecutter.problem_name}}/solution.py +0 -0
  214. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/resources/leetcode/{{cookiecutter.problem_name}}/test_solution.py +0 -0
  215. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/utils/__init__.py +0 -0
  216. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/utils/problem_finder.py +0 -0
  217. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/utils/resources.py +0 -0
  218. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/cli/utils/tag_helpers.py +0 -0
  219. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/data_structures/__init__.py +0 -0
  220. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/data_structures/_utils.py +0 -0
  221. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/data_structures/dict_tree.py +0 -0
  222. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/data_structures/doubly_list_node.py +0 -0
  223. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/data_structures/graph_node.py +0 -0
  224. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/data_structures/list_node.py +0 -0
  225. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/data_structures/tree_node.py +0 -0
  226. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/py.typed +0 -0
  227. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/tools/__init__.py +0 -0
  228. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/tools/check_test_cases.py +0 -0
  229. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/tools/generator.py +0 -0
  230. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/tools/logged_test.py +0 -0
  231. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/tools/parser.py +0 -0
  232. {leetcode_py_sdk-0.44.0 → leetcode_py_sdk-0.46.0}/src/leetcode_py/tools/scraper.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: leetcode-py-sdk
3
- Version: 0.44.0
3
+ Version: 0.46.0
4
4
  Summary: Modern Python LeetCode practice environment with automated problem generation, beautiful data structure visualizations, and comprehensive testing
5
5
  Keywords: algorithms,coding-practice,data-structures,interview-prep,leetcode
6
6
  Author: Wisaroot Lertthaweedech
@@ -79,7 +79,7 @@ A Python package to generate professional LeetCode practice environments. Featur
79
79
  - **grind-75** - Essential coding interview questions from [Grind 75](https://www.techinterviewhandbook.org/grind75/) ✅ Complete
80
80
  - **grind** - Extended Grind collection including all Grind 75 plus additional problems 🚧 Partial
81
81
  - **blind-75** - Original [Blind 75](https://leetcode.com/problem-list/xi4ci4ig/) curated list ✅ Complete
82
- - **neetcode-150** - Comprehensive [NeetCode 150](https://neetcode.io/practice) problem set 🚧 Partial
82
+ - **neetcode-150** - Comprehensive [NeetCode 150](https://neetcode.io/practice) problem set Complete
83
83
  - **algo-master-75** - Curated algorithmic mastery problems ✅ Complete
84
84
 
85
85
  **Coverage**: 130+ unique problems across all major coding interview topics and difficulty levels.
@@ -43,7 +43,7 @@ A Python package to generate professional LeetCode practice environments. Featur
43
43
  - **grind-75** - Essential coding interview questions from [Grind 75](https://www.techinterviewhandbook.org/grind75/) ✅ Complete
44
44
  - **grind** - Extended Grind collection including all Grind 75 plus additional problems 🚧 Partial
45
45
  - **blind-75** - Original [Blind 75](https://leetcode.com/problem-list/xi4ci4ig/) curated list ✅ Complete
46
- - **neetcode-150** - Comprehensive [NeetCode 150](https://neetcode.io/practice) problem set 🚧 Partial
46
+ - **neetcode-150** - Comprehensive [NeetCode 150](https://neetcode.io/practice) problem set Complete
47
47
  - **algo-master-75** - Curated algorithmic mastery problems ✅ Complete
48
48
 
49
49
  **Coverage**: 130+ unique problems across all major coding interview topics and difficulty levels.
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "leetcode-py-sdk"
3
- version = "0.44.0" # use git tag instead
3
+ version = "0.46.0" # use git tag instead
4
4
  description = "Modern Python LeetCode practice environment with automated problem generation, beautiful data structure visualizations, and comprehensive testing"
5
5
  authors = [
6
6
  {name = "Wisaroot Lertthaweedech", email = "l.wisaroot@gmail.com"}
@@ -0,0 +1,89 @@
1
+ {
2
+ "problem_name": "best_time_to_buy_and_sell_stock_with_cooldown",
3
+ "solution_class_name": "Solution",
4
+ "problem_number": "309",
5
+ "problem_title": "Best Time to Buy and Sell Stock with Cooldown",
6
+ "difficulty": "Medium",
7
+ "topics": "Array, Dynamic Programming",
8
+ "_tags": {
9
+ "list": ["neetcode-150"]
10
+ },
11
+ "readme_description": "You are given an array `prices` where `prices[i]` is the price of a given stock on the `ith` day.\n\nFind the maximum profit you can achieve. You may complete as many transactions as you like (i.e., buy one and sell one share of the stock multiple times) with the following restrictions:\n\n- After you sell your stock, you cannot buy stock on the next day (i.e., cooldown one day).\n\n**Note:** You may not engage in multiple transactions simultaneously (i.e., you must sell the stock before you buy again).",
12
+ "_readme_examples": {
13
+ "list": [
14
+ {
15
+ "content": "```\nInput: prices = [1,2,3,0,2]\nOutput: 3\n```\n**Explanation:** transactions = [buy, sell, cooldown, buy, sell]"
16
+ },
17
+ {
18
+ "content": "```\nInput: prices = [1]\nOutput: 0\n```"
19
+ }
20
+ ]
21
+ },
22
+ "readme_constraints": "- 1 <= prices.length <= 5000\n- 0 <= prices[i] <= 1000",
23
+ "readme_additional": "",
24
+ "helpers_imports": "",
25
+ "helpers_content": "",
26
+ "helpers_run_name": "max_profit",
27
+ "helpers_run_signature": "(solution_class: type, prices: list[int])",
28
+ "helpers_run_body": " implementation = solution_class()\n return implementation.max_profit(prices)",
29
+ "helpers_assert_name": "max_profit",
30
+ "helpers_assert_signature": "(result: int, expected: int) -> bool",
31
+ "helpers_assert_body": " assert result == expected\n return True",
32
+ "solution_imports": "",
33
+ "solution_contents": "",
34
+ "solution_class_content": "",
35
+ "test_imports": "import pytest\nfrom leetcode_py import logged_test\nfrom .helpers import assert_max_profit, run_max_profit\nfrom .solution import Solution",
36
+ "test_content": "",
37
+ "test_class_name": "BestTimeToBuyAndSellStockWithCooldown",
38
+ "test_class_content": " def setup_method(self):\n self.solution = Solution()",
39
+ "_solution_methods": {
40
+ "list": [
41
+ {
42
+ "name": "max_profit",
43
+ "signature": "(self, prices: list[int]) -> int",
44
+ "body": " # TODO: Implement max_profit\n return 0"
45
+ }
46
+ ]
47
+ },
48
+ "_test_helper_methods": {
49
+ "list": [
50
+ {
51
+ "name": "setup_method",
52
+ "parameters": "",
53
+ "body": "self.solution = Solution()"
54
+ }
55
+ ]
56
+ },
57
+ "_test_methods": {
58
+ "list": [
59
+ {
60
+ "name": "test_max_profit",
61
+ "signature": "(self, prices: list[int], expected: int)",
62
+ "parametrize": "prices, expected",
63
+ "test_cases": {
64
+ "list": [
65
+ "([1, 2, 3, 0, 2], 3)",
66
+ "([1], 0)",
67
+ "([1, 2], 1)",
68
+ "([3, 2, 1], 0)",
69
+ "([1, 2, 3], 2)",
70
+ "([1, 2, 4], 3)",
71
+ "([2, 4, 1], 2)",
72
+ "([1, 4, 2], 3)",
73
+ "([1, 2, 3, 0, 2, 5], 6)",
74
+ "([6, 1, 6, 4, 2, 0, 1], 6)",
75
+ "([5], 0)",
76
+ "([1, 2, 3, 4, 5], 4)",
77
+ "([1, 3, 1, 4], 3)",
78
+ "([2, 1], 0)"
79
+ ]
80
+ },
81
+ "body": " result = run_max_profit(Solution, prices)\n assert_max_profit(result, expected)"
82
+ }
83
+ ]
84
+ },
85
+ "playground_imports": "from helpers import run_max_profit, assert_max_profit\nfrom solution import Solution",
86
+ "playground_setup": "# Example test case\nprices = [1, 2, 3, 0, 2]\nexpected = 3",
87
+ "playground_run": "result = run_max_profit(Solution, prices)\nresult",
88
+ "playground_assert": "assert_max_profit(result, expected)"
89
+ }
@@ -0,0 +1,89 @@
1
+ {
2
+ "problem_name": "burst_balloons",
3
+ "solution_class_name": "Solution",
4
+ "problem_number": "312",
5
+ "problem_title": "Burst Balloons",
6
+ "difficulty": "Hard",
7
+ "topics": "Array, Dynamic Programming",
8
+ "_tags": {
9
+ "list": ["neetcode-150"]
10
+ },
11
+ "readme_description": "You are given `n` balloons, indexed from `0` to `n - 1`. Each balloon is painted with a number on it represented by an array `nums`. You are asked to burst all the balloons.\n\nIf you burst the `ith` balloon, you will get `nums[i - 1] * nums[i] * nums[i + 1]` coins. If `i - 1` or `i + 1` goes out of bounds of the array, then treat it as if there is a balloon with a `1` painted on it.\n\nReturn *the maximum coins you can collect by bursting the balloons wisely*.",
12
+ "_readme_examples": {
13
+ "list": [
14
+ {
15
+ "content": "```\nInput: nums = [3,1,5,8]\nOutput: 167\n```\n**Explanation:**\nnums = [3,1,5,8] --> [3,5,8] --> [3,8] --> [8] --> []\ncoins = 3*1*5 + 3*5*8 + 1*3*8 + 1*8*1 = 167"
16
+ },
17
+ {
18
+ "content": "```\nInput: nums = [1,5]\nOutput: 10\n```"
19
+ }
20
+ ]
21
+ },
22
+ "readme_constraints": "- n == nums.length\n- 1 <= n <= 300\n- 0 <= nums[i] <= 100",
23
+ "readme_additional": "",
24
+ "helpers_imports": "",
25
+ "helpers_content": "",
26
+ "helpers_run_name": "max_coins",
27
+ "helpers_run_signature": "(solution_class: type, nums: list[int])",
28
+ "helpers_run_body": " implementation = solution_class()\n return implementation.max_coins(nums)",
29
+ "helpers_assert_name": "max_coins",
30
+ "helpers_assert_signature": "(result: int, expected: int) -> bool",
31
+ "helpers_assert_body": " assert result == expected\n return True",
32
+ "solution_imports": "",
33
+ "solution_contents": "",
34
+ "solution_class_content": "",
35
+ "test_imports": "import pytest\nfrom leetcode_py import logged_test\nfrom .helpers import assert_max_coins, run_max_coins\nfrom .solution import Solution",
36
+ "test_content": "",
37
+ "test_class_name": "BurstBalloons",
38
+ "test_class_content": " def setup_method(self):\n self.solution = Solution()",
39
+ "_solution_methods": {
40
+ "list": [
41
+ {
42
+ "name": "max_coins",
43
+ "signature": "(self, nums: list[int]) -> int",
44
+ "body": " # TODO: Implement max_coins\n return 0"
45
+ }
46
+ ]
47
+ },
48
+ "_test_helper_methods": {
49
+ "list": [
50
+ {
51
+ "name": "setup_method",
52
+ "parameters": "",
53
+ "body": "self.solution = Solution()"
54
+ }
55
+ ]
56
+ },
57
+ "_test_methods": {
58
+ "list": [
59
+ {
60
+ "name": "test_max_coins",
61
+ "signature": "(self, nums: list[int], expected: int)",
62
+ "parametrize": "nums, expected",
63
+ "test_cases": {
64
+ "list": [
65
+ "([3, 1, 5, 8], 167)",
66
+ "([1, 5], 10)",
67
+ "([5], 5)",
68
+ "([1], 1)",
69
+ "([0], 0)",
70
+ "([100], 100)",
71
+ "([0, 0, 0], 0)",
72
+ "([2], 2)",
73
+ "([1, 2], 4)",
74
+ "([2, 2], 6)",
75
+ "([1, 2, 3], 12)",
76
+ "([3, 2, 1], 12)",
77
+ "([3, 1, 5], 35)",
78
+ "([4, 6, 7, 9], 639)"
79
+ ]
80
+ },
81
+ "body": " result = run_max_coins(Solution, nums)\n assert_max_coins(result, expected)"
82
+ }
83
+ ]
84
+ },
85
+ "playground_imports": "from helpers import run_max_coins, assert_max_coins\nfrom solution import Solution",
86
+ "playground_setup": "# Example test case\nnums = [3, 1, 5, 8]\nexpected = 167",
87
+ "playground_run": "result = run_max_coins(Solution, nums)\nresult",
88
+ "playground_assert": "assert_max_coins(result, expected)"
89
+ }
@@ -0,0 +1,91 @@
1
+ {
2
+ "problem_name": "car_fleet",
3
+ "solution_class_name": "Solution",
4
+ "problem_number": "853",
5
+ "problem_title": "Car Fleet",
6
+ "difficulty": "Medium",
7
+ "topics": "Array, Stack, Sorting, Monotonic Stack",
8
+ "_tags": {
9
+ "list": ["neetcode-150"]
10
+ },
11
+ "readme_description": "There are `n` cars at given miles away from the starting mile 0, traveling to reach the mile `target`.\n\nYou are given two integer arrays `position` and `speed`, both of length `n`, where `position[i]` is the starting mile of the `i<sup>th</sup>` car and `speed[i]` is the speed of the `i<sup>th</sup>` car in miles per hour.\n\nA car cannot pass another car, but it can catch up and then travel next to it at the speed of the slower car.\n\nA **car fleet** is a single car or a group of cars driving next to each other. The speed of the car fleet is the **minimum** speed of any car in the fleet.\n\nIf a car catches up to a car fleet at the mile `target`, it will still be considered as part of the car fleet.\n\nReturn the number of car fleets that will arrive at the destination.",
12
+ "_readme_examples": {
13
+ "list": [
14
+ {
15
+ "content": "```\nInput: target = 12, position = [10,8,0,5,3], speed = [2,4,1,1,3]\nOutput: 3\nExplanation:\n- The cars starting at 10 (speed 2) and 8 (speed 4) become a fleet, meeting each other at 12. The fleet forms at target.\n- The car starting at 0 (speed 1) does not catch up to any other car, so it is a fleet by itself.\n- The cars starting at 5 (speed 1) and 3 (speed 3) become a fleet, meeting each other at 6. The fleet moves at speed 1 until it reaches target.\n```"
16
+ },
17
+ {
18
+ "content": "```\nInput: target = 10, position = [3], speed = [3]\nOutput: 1\nExplanation: There is only one car, hence there is only one fleet.\n```"
19
+ },
20
+ {
21
+ "content": "```\nInput: target = 100, position = [0,2,4], speed = [4,2,1]\nOutput: 1\n```"
22
+ }
23
+ ]
24
+ },
25
+ "readme_constraints": "- n == position.length == speed.length\n- 1 <= n <= 10<sup>5</sup>\n- 0 < target <= 10<sup>6</sup>\n- 0 <= position[i] < target\n- All the values of position are **unique**.\n- 0 < speed[i] <= 10<sup>6</sup>",
26
+ "readme_additional": "",
27
+ "helpers_imports": "",
28
+ "helpers_content": "",
29
+ "helpers_run_name": "car_fleet",
30
+ "helpers_run_signature": "(solution_class: type, target: int, position: list[int], speed: list[int])",
31
+ "helpers_run_body": " implementation = solution_class()\n return implementation.car_fleet(target, position, speed)",
32
+ "helpers_assert_name": "car_fleet",
33
+ "helpers_assert_signature": "(result: int, expected: int) -> bool",
34
+ "helpers_assert_body": " assert result == expected\n return True",
35
+ "solution_imports": "",
36
+ "solution_contents": "",
37
+ "solution_class_content": "",
38
+ "test_imports": "import pytest\nfrom leetcode_py import logged_test\nfrom .helpers import assert_car_fleet, run_car_fleet\nfrom .solution import Solution",
39
+ "test_content": "",
40
+ "test_class_name": "CarFleet",
41
+ "test_class_content": " def setup_method(self):\n self.solution = Solution()",
42
+ "_solution_methods": {
43
+ "list": [
44
+ {
45
+ "name": "car_fleet",
46
+ "signature": "(self, target: int, position: list[int], speed: list[int]) -> int",
47
+ "body": " # TODO: Implement car_fleet\n return 0"
48
+ }
49
+ ]
50
+ },
51
+ "_test_helper_methods": {
52
+ "list": [
53
+ {
54
+ "name": "setup_method",
55
+ "parameters": "",
56
+ "body": "self.solution = Solution()"
57
+ }
58
+ ]
59
+ },
60
+ "_test_methods": {
61
+ "list": [
62
+ {
63
+ "name": "test_car_fleet",
64
+ "signature": "(self, target: int, position: list[int], speed: list[int], expected: int)",
65
+ "parametrize": "target, position, speed, expected",
66
+ "test_cases": {
67
+ "list": [
68
+ "(12, [10, 8, 0, 5, 3], [2, 4, 1, 1, 3], 3)",
69
+ "(10, [3], [3], 1)",
70
+ "(100, [0, 2, 4], [4, 2, 1], 1)",
71
+ "(10, [0], [1], 1)",
72
+ "(20, [10, 15], [5, 1], 1)",
73
+ "(100, [0, 1, 2], [1, 1, 1], 3)",
74
+ "(10, [0, 2, 4, 6, 8], [1, 1, 1, 1, 1], 5)",
75
+ "(10, [8, 6, 4, 2, 0], [2, 4, 6, 8, 10], 1)",
76
+ "(15, [1, 5, 10], [4, 2, 1], 1)",
77
+ "(20, [6, 10, 15], [2, 3, 1], 2)",
78
+ "(5, [1, 3], [1, 2], 2)",
79
+ "(20, [5, 10], [5, 5], 2)",
80
+ "(50, [10, 20, 30, 40], [1, 1, 1, 1], 4)"
81
+ ]
82
+ },
83
+ "body": " result = run_car_fleet(Solution, target, position, speed)\n assert_car_fleet(result, expected)"
84
+ }
85
+ ]
86
+ },
87
+ "playground_imports": "from helpers import run_car_fleet, assert_car_fleet\nfrom solution import Solution",
88
+ "playground_setup": "# Example test case\ntarget = 12\nposition = [10, 8, 0, 5, 3]\nspeed = [2, 4, 1, 1, 3]\nexpected = 3",
89
+ "playground_run": "result = run_car_fleet(Solution, target, position, speed)\nresult",
90
+ "playground_assert": "assert_car_fleet(result, expected)"
91
+ }
@@ -0,0 +1,92 @@
1
+ {
2
+ "problem_name": "coin_change_ii",
3
+ "solution_class_name": "Solution",
4
+ "problem_number": "518",
5
+ "problem_title": "Coin Change II",
6
+ "difficulty": "Medium",
7
+ "topics": "Array, Dynamic Programming",
8
+ "_tags": {
9
+ "list": ["neetcode-150"]
10
+ },
11
+ "readme_description": "You are given an integer array `coins` representing coins of different denominations and an integer `amount` representing a total amount of money.\n\nReturn *the number of combinations that make up that amount*. If that amount of money cannot be made up by any combination of the coins, return `0`.\n\nYou may assume that you have an infinite number of each kind of coin.\n\nThe final answer is **guaranteed** to fit into a signed 32-bit integer.",
12
+ "_readme_examples": {
13
+ "list": [
14
+ {
15
+ "content": "```\nInput: amount = 5, coins = [1,2,5]\nOutput: 4\n```\n**Explanation:** there are four ways to make up the amount:\n5=5\n5=2+2+1\n5=2+1+1+1\n5=1+1+1+1+1"
16
+ },
17
+ {
18
+ "content": "```\nInput: amount = 3, coins = [2]\nOutput: 0\n```\n**Explanation:** the amount of 3 cannot be made up just with coins of 2."
19
+ },
20
+ {
21
+ "content": "```\nInput: amount = 10, coins = [10]\nOutput: 1\n```"
22
+ }
23
+ ]
24
+ },
25
+ "readme_constraints": "- 1 <= coins.length <= 300\n- 1 <= coins[i] <= 5000\n- All the values of `coins` are **unique**.\n- 0 <= amount <= 5000",
26
+ "readme_additional": "",
27
+ "helpers_imports": "",
28
+ "helpers_content": "",
29
+ "helpers_run_name": "change",
30
+ "helpers_run_signature": "(solution_class: type, amount: int, coins: list[int])",
31
+ "helpers_run_body": " implementation = solution_class()\n return implementation.change(amount, coins)",
32
+ "helpers_assert_name": "change",
33
+ "helpers_assert_signature": "(result: int, expected: int) -> bool",
34
+ "helpers_assert_body": " assert result == expected\n return True",
35
+ "solution_imports": "",
36
+ "solution_contents": "",
37
+ "solution_class_content": "",
38
+ "test_imports": "import pytest\nfrom leetcode_py import logged_test\nfrom .helpers import assert_change, run_change\nfrom .solution import Solution",
39
+ "test_content": "",
40
+ "test_class_name": "CoinChangeII",
41
+ "test_class_content": " def setup_method(self):\n self.solution = Solution()",
42
+ "_solution_methods": {
43
+ "list": [
44
+ {
45
+ "name": "change",
46
+ "signature": "(self, amount: int, coins: list[int]) -> int",
47
+ "body": " # TODO: Implement change\n return 0"
48
+ }
49
+ ]
50
+ },
51
+ "_test_helper_methods": {
52
+ "list": [
53
+ {
54
+ "name": "setup_method",
55
+ "parameters": "",
56
+ "body": "self.solution = Solution()"
57
+ }
58
+ ]
59
+ },
60
+ "_test_methods": {
61
+ "list": [
62
+ {
63
+ "name": "test_change",
64
+ "signature": "(self, amount: int, coins: list[int], expected: int)",
65
+ "parametrize": "amount, coins, expected",
66
+ "test_cases": {
67
+ "list": [
68
+ "(5, [1, 2, 5], 4)",
69
+ "(3, [2], 0)",
70
+ "(10, [10], 1)",
71
+ "(0, [1, 2, 5], 1)",
72
+ "(4, [1, 2], 3)",
73
+ "(5, [2], 0)",
74
+ "(1, [2], 0)",
75
+ "(3, [1, 2], 2)",
76
+ "(6, [1, 2, 3], 7)",
77
+ "(2, [1], 1)",
78
+ "(100, [1, 2, 5], 541)",
79
+ "(7, [2, 3, 6], 1)",
80
+ "(8, [2, 3, 5], 3)",
81
+ "(500, [3, 5, 7], 1227)"
82
+ ]
83
+ },
84
+ "body": " result = run_change(Solution, amount, coins)\n assert_change(result, expected)"
85
+ }
86
+ ]
87
+ },
88
+ "playground_imports": "from helpers import run_change, assert_change\nfrom solution import Solution",
89
+ "playground_setup": "# Example test case\namount = 5\ncoins = [1, 2, 5]\nexpected = 4",
90
+ "playground_run": "result = run_change(Solution, amount, coins)\nresult",
91
+ "playground_assert": "assert_change(result, expected)"
92
+ }
@@ -0,0 +1,91 @@
1
+ {
2
+ "problem_name": "copy_list_with_random_pointer",
3
+ "solution_class_name": "Solution",
4
+ "problem_number": "138",
5
+ "problem_title": "Copy List with Random Pointer",
6
+ "difficulty": "Medium",
7
+ "topics": "Hash Table, Linked List",
8
+ "_tags": {
9
+ "list": ["neetcode-150"]
10
+ },
11
+ "readme_description": "A linked list of length `n` is given such that each node contains an additional **random pointer**, which could point to any node in the list, or `null`.\n\nConstruct a [**deep copy**](https://en.wikipedia.org/wiki/Object_copying#Deep_copy) of the list. The deep copy should consist of exactly `n` **brand new** nodes, where each new node has its value set to the value of its corresponding original node. Both the `next` and `random` pointer of the new nodes should point to new nodes in the copied list such that the pointers in the original list and copied list represent the same list state. **None of the pointers in the new list should point to nodes in the original list**.\n\nReturn *the head of the copied linked list*.\n\nThe linked list is represented in the input/output as a list of `n` nodes. Each node is represented as a pair of `[val, random_index]` where:\n\n- `val`: an integer representing `Node.val`\n- `random_index`: the index of the node (range from `0` to `n-1`) that the `random` pointer points to, or `null` if it does not point to any node.",
12
+ "_readme_examples": {
13
+ "list": [
14
+ {
15
+ "content": "![Example 1](https://assets.leetcode.com/uploads/2019/12/18/e1.png)\n\n```\nInput: head = [[7,null],[13,0],[11,4],[10,2],[1,0]]\nOutput: [[7,null],[13,0],[11,4],[10,2],[1,0]]\n```"
16
+ },
17
+ {
18
+ "content": "![Example 2](https://assets.leetcode.com/uploads/2019/12/18/e2.png)\n\n```\nInput: head = [[1,1],[2,1]]\nOutput: [[1,1],[2,1]]\n```"
19
+ },
20
+ {
21
+ "content": "![Example 3](https://assets.leetcode.com/uploads/2019/12/18/e3.png)\n\n```\nInput: head = [[3,null],[3,0],[3,null]]\nOutput: [[3,null],[3,0],[3,null]]\n```"
22
+ }
23
+ ]
24
+ },
25
+ "readme_constraints": "- 0 <= n <= 1000\n- -10^4 <= Node.val <= 10^4\n- Node.random is null or points to some node in the linked list.",
26
+ "readme_additional": "",
27
+ "helpers_imports": "from .solution import Node",
28
+ "helpers_content": "def _build_random_list(nodes: list[list[int | None]]) -> Node | None:\n if not nodes:\n return None\n created: list[Node] = []\n for node_spec in nodes:\n val = node_spec[0]\n assert isinstance(val, int)\n created.append(Node(val))\n for i, node_spec in enumerate(nodes):\n if i + 1 < len(created):\n created[i].next = created[i + 1]\n rand_idx = node_spec[1]\n if rand_idx is not None:\n created[i].random = created[rand_idx]\n return created[0]\n\n\ndef _serialize_random_list(head: Node | None) -> list[list[int | None]]:\n index_by_id: dict[int, int] = {}\n cur: Node | None = head\n i = 0\n while cur is not None:\n index_by_id[id(cur)] = i\n i += 1\n cur = cur.next\n result: list[list[int | None]] = []\n cur = head\n while cur is not None:\n rand_idx = index_by_id[id(cur.random)] if cur.random is not None else None\n result.append([cur.val, rand_idx])\n cur = cur.next\n return result",
29
+ "helpers_run_name": "copy_random_list",
30
+ "helpers_run_signature": "(solution_class: type, nodes: list[list[int | None]])",
31
+ "helpers_run_body": " implementation = solution_class()\n head = _build_random_list(nodes)\n copied = implementation.copy_random_list(head)\n return _serialize_random_list(copied)",
32
+ "helpers_assert_name": "copy_random_list",
33
+ "helpers_assert_signature": "(result: list[list[int | None]], expected: list[list[int | None]]) -> bool",
34
+ "helpers_assert_body": " assert result == expected\n return True",
35
+ "solution_imports": "from __future__ import annotations",
36
+ "solution_contents": "class Node:\n def __init__(self, x: int, next: Node | None = None, random: Node | None = None):\n self.val = int(x)\n self.next = next\n self.random = random\n\n\n",
37
+ "solution_class_content": "",
38
+ "test_imports": "import pytest\nfrom leetcode_py import logged_test\nfrom .helpers import assert_copy_random_list, run_copy_random_list\nfrom .solution import Solution",
39
+ "test_content": "",
40
+ "test_class_name": "CopyListWithRandomPointer",
41
+ "test_class_content": " def setup_method(self):\n self.solution = Solution()",
42
+ "_solution_methods": {
43
+ "list": [
44
+ {
45
+ "name": "copy_random_list",
46
+ "signature": "(self, head: Node | None) -> Node | None",
47
+ "body": " # TODO: Implement copy_random_list\n return None"
48
+ }
49
+ ]
50
+ },
51
+ "_test_helper_methods": {
52
+ "list": [
53
+ {
54
+ "name": "setup_method",
55
+ "parameters": "",
56
+ "body": "self.solution = Solution()"
57
+ }
58
+ ]
59
+ },
60
+ "_test_methods": {
61
+ "list": [
62
+ {
63
+ "name": "test_copy_random_list",
64
+ "signature": "(self, nodes: list[list[int | None]], expected: list[list[int | None]])",
65
+ "parametrize": "nodes, expected",
66
+ "test_cases": {
67
+ "list": [
68
+ "([[7, None], [13, 0], [11, 4], [10, 2], [1, 0]], [[7, None], [13, 0], [11, 4], [10, 2], [1, 0]])",
69
+ "([[1, 1], [2, 1]], [[1, 1], [2, 1]])",
70
+ "([[3, None], [3, 0], [3, None]], [[3, None], [3, 0], [3, None]])",
71
+ "([], [])",
72
+ "([[1, None]], [[1, None]])",
73
+ "([[1, 0]], [[1, 0]])",
74
+ "([[1, None], [2, None]], [[1, None], [2, None]])",
75
+ "([[5, 1], [6, None], [7, 0]], [[5, 1], [6, None], [7, 0]])",
76
+ "([[0, None], [1, 0], [2, 1], [3, 2]], [[0, None], [1, 0], [2, 1], [3, 2]])",
77
+ "([[1, None], [2, 2], [3, 2]], [[1, None], [2, 2], [3, 2]])",
78
+ "([[42, None]], [[42, None]])",
79
+ "([[1, 2], [2, None], [3, 0]], [[1, 2], [2, None], [3, 0]])",
80
+ "([[1, None], [2, 0], [3, 1], [4, 2]], [[1, None], [2, 0], [3, 1], [4, 2]])"
81
+ ]
82
+ },
83
+ "body": " result = run_copy_random_list(Solution, nodes)\n assert_copy_random_list(result, expected)"
84
+ }
85
+ ]
86
+ },
87
+ "playground_imports": "from helpers import run_copy_random_list, assert_copy_random_list\nfrom solution import Node, Solution",
88
+ "playground_setup": "# Example test case (each node is [val, random_index])\nnodes = [[7, None], [13, 0], [11, 4], [10, 2], [1, 0]]\nexpected = [[7, None], [13, 0], [11, 4], [10, 2], [1, 0]]",
89
+ "playground_run": "result = run_copy_random_list(Solution, nodes)\nresult",
90
+ "playground_assert": "assert_copy_random_list(result, expected)"
91
+ }
@@ -0,0 +1,95 @@
1
+ {
2
+ "problem_name": "count_good_nodes_in_binary_tree",
3
+ "solution_class_name": "Solution",
4
+ "problem_number": "1448",
5
+ "problem_title": "Count Good Nodes in Binary Tree",
6
+ "difficulty": "Medium",
7
+ "topics": "Tree, Depth-First Search, Breadth-First Search, Binary Tree",
8
+ "_tags": {
9
+ "list": ["neetcode-150"]
10
+ },
11
+ "readme_description": "Given a binary tree `root`, a node *X* in the tree is named **good** if in the path from root to *X* there are no nodes with a value *greater than* X.\n\nReturn the number of **good** nodes in the binary tree.",
12
+ "_readme_examples": {
13
+ "list": [
14
+ {
15
+ "content": "![Example 1](https://assets.leetcode.com/uploads/2020/04/02/test_sample_1.png)\n\n```\nInput: root = [3,1,4,3,null,1,5]\nOutput: 4\nExplanation: Nodes in blue are good.\nRoot Node (3) is always a good node.\nNode 4 -> (3,4) is the maximum value in the path starting from the root.\nNode 5 -> (3,4,5) is the maximum value in the path.\nNode 3 -> (3,1,3) is the maximum value in the path.\n```"
16
+ },
17
+ {
18
+ "content": "![Example 2](https://assets.leetcode.com/uploads/2020/04/02/test_sample_2.png)\n\n```\nInput: root = [3,3,null,4,2]\nOutput: 3\nExplanation: Node 2 -> (3,3,2) is not good, because \"3\" is higher than it.\n```"
19
+ },
20
+ {
21
+ "content": "```\nInput: root = [1]\nOutput: 1\nExplanation: Root is considered as good.\n```"
22
+ }
23
+ ]
24
+ },
25
+ "readme_constraints": "- The number of nodes in the binary tree is in the range `[1, 10^5]`.\n- Each node's value is between `[-10^4, 10^4]`.",
26
+ "readme_additional": "",
27
+ "helpers_imports": "from leetcode_py import TreeNode",
28
+ "helpers_content": "",
29
+ "helpers_run_name": "good_nodes",
30
+ "helpers_run_signature": "(solution_class: type, root_list: list[int | None])",
31
+ "helpers_run_body": " implementation = solution_class()\n root = TreeNode.from_list(root_list) if root_list else None\n return implementation.good_nodes(root)",
32
+ "helpers_assert_name": "good_nodes",
33
+ "helpers_assert_signature": "(result: int, expected: int) -> bool",
34
+ "helpers_assert_body": " assert result == expected\n return True",
35
+ "solution_imports": "from leetcode_py import TreeNode",
36
+ "solution_contents": "",
37
+ "solution_class_content": "",
38
+ "test_imports": "import pytest\nfrom leetcode_py import logged_test\nfrom .helpers import assert_good_nodes, run_good_nodes\nfrom .solution import Solution",
39
+ "test_content": "",
40
+ "test_class_name": "CountGoodNodesInBinaryTree",
41
+ "test_class_content": " def setup_method(self):\n self.solution = Solution()",
42
+ "_solution_methods": {
43
+ "list": [
44
+ {
45
+ "name": "good_nodes",
46
+ "signature": "(self, root: TreeNode[int] | None) -> int",
47
+ "body": " # TODO: Implement good_nodes\n return 0"
48
+ }
49
+ ]
50
+ },
51
+ "_test_helper_methods": {
52
+ "list": [
53
+ {
54
+ "name": "setup_method",
55
+ "parameters": "",
56
+ "body": "self.solution = Solution()"
57
+ }
58
+ ]
59
+ },
60
+ "_test_methods": {
61
+ "list": [
62
+ {
63
+ "name": "test_good_nodes",
64
+ "signature": "(self, root_list: list[int | None], expected: int)",
65
+ "parametrize": "root_list, expected",
66
+ "test_cases": {
67
+ "list": [
68
+ "([3, 1, 4, 3, None, 1, 5], 4)",
69
+ "([3, 3, None, 4, 2], 3)",
70
+ "([1], 1)",
71
+ "([], 0)",
72
+ "([5], 1)",
73
+ "([2, 1], 1)",
74
+ "([2, 3], 2)",
75
+ "([1, 2, 3], 3)",
76
+ "([3, 2, 1], 1)",
77
+ "([-1, -2, -3], 1)",
78
+ "([-3, -1, -4], 2)",
79
+ "([1, 2, 3, 4, 5, 6, 7], 7)",
80
+ "([7, 6, 5, 4, 3, 2, 1], 1)",
81
+ "([10, 5, 15], 2)",
82
+ "([10, 10, 10], 3)",
83
+ "([4, 2, 6, 1, 3, 5, 7], 3)",
84
+ "([1, 1, 1, 1, None, 1, 1], 6)"
85
+ ]
86
+ },
87
+ "body": " result = run_good_nodes(Solution, root_list)\n assert_good_nodes(result, expected)"
88
+ }
89
+ ]
90
+ },
91
+ "playground_imports": "from helpers import run_good_nodes, assert_good_nodes\nfrom solution import Solution\nfrom leetcode_py import TreeNode",
92
+ "playground_setup": "# Example test case\nroot_list: list[int | None] = [3, 1, 4, 3, None, 1, 5]\nexpected = 4",
93
+ "playground_run": "result = run_good_nodes(Solution, root_list)\nresult",
94
+ "playground_assert": "assert_good_nodes(result, expected)"
95
+ }