Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Implement sliding window algorithms for fixed and dynamic sizes with tests #1765

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

Merged
raklaptudirm merged 2 commits into TheAlgorithms:master from Kesavan-77:master
Sep 4, 2025

Conversation

Copy link
Contributor

@Kesavan-77 Kesavan-77 commented Nov 5, 2024

Sliding Windows Algorithm

  • Added maxSumSubarrayFixed function to calculate the maximum sum of a fixed-size subarray.
  • Added longestSubarrayWithSumAtMost function to find the longest subarray with a sum less than or equal to a given target.
  • Included tests for both functions to ensure correctness and edge case handling.
  • Updated documentation to reflect the new implementations.

Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84.80%. Comparing base (55ff0ad) to head (a3c5ac0).

Additional details and impacted files
@@ Coverage Diff @@
## master #1765 +/- ##
==========================================
+ Coverage 84.76% 84.80% +0.03% 
==========================================
 Files 378 380 +2 
 Lines 19738 19785 +47 
 Branches 2957 2965 +8 
==========================================
+ Hits 16731 16778 +47 
 Misses 3007 3007 

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

Copy link
Contributor Author

@raklaptudirm , @appgurueu kindly check the above PR for merging.

Copy link
Contributor Author

Kindly merge the above PR @raklaptudirm and @appgurueu

@raklaptudirm raklaptudirm merged commit 3f52add into TheAlgorithms:master Sep 4, 2025
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@raklaptudirm raklaptudirm raklaptudirm approved these changes

@appgurueu appgurueu Awaiting requested review from appgurueu appgurueu is a code owner

+2 more reviewers

@pertrai1 pertrai1 pertrai1 approved these changes

@anandfresh anandfresh anandfresh approved these changes

Reviewers whose approvals may not affect merge requirements
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /