Skip to content

Added Trapping Rain Water code in java #5930

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed

Conversation

maitreepatel1110
Copy link

Implemented optimal solution for Trapping Rain Water problem using two-pointer approach with O(n) time complexity and O(1) space complexity. Given detailed explanation of approach with test cases for the given algorithm.

  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized it.
  • All filenames are in PascalCase.
  • All functions and variable names follow Java naming conventions.
  • All new algorithms have a URL in their comments that points to Wikipedia or other similar explanations.
  • All new code is formatted with clang-format -i --style=file path/to/your/file.java

Implemented optimal solution for Trapping Rain Water problem using two-pointer approach with O(n) time complexity and O(1) space complexity.
Given detailed explanation of approach with test cases for the given algorithm.
@codecov-commenter
Copy link

codecov-commenter commented Oct 21, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 67.11%. Comparing base (6006025) to head (5a76df4).

Additional details and impacted files
@@             Coverage Diff              @@
##             master    #5930      +/-   ##
============================================
+ Coverage     67.10%   67.11%   +0.01%     
- Complexity     4560     4561       +1     
============================================
  Files           619      619              
  Lines         17098    17098              
  Branches       3296     3296              
============================================
+ Hits          11474    11476       +2     
+ Misses         5168     5167       -1     
+ Partials        456      455       -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@siriak
Copy link
Member

siriak commented Oct 23, 2024

We don't add leetcode problems

@siriak siriak closed this Oct 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants