Add MaxAlternatingSum algorithm implementation
This PR adds a Java implementation of Max Alternating Sum to the devutils package.
Includes: ✔ Javadoc documentation ✔ Clean formatting and package declaration ✔ Sorting + arithmetic based optimal algorithm ✔ Follows TheAlgorithms conventions
Time Complexity: O(n log n) Space Complexity: O(n)
Codecov Report
:x: Patch coverage is 0% with 14 lines in your changes missing coverage. Please review.
:white_check_mark: Project coverage is 78.44%. Comparing base (fa8ea8e) to head (3e1a4b2).
| Files with missing lines | Patch % | Lines |
|---|---|---|
| .../com/thealgorithms/devutils/MaxAlternatingSum.java | 0.00% | 14 Missing :warning: |
Additional details and impacted files
@@ Coverage Diff @@
## master #7085 +/- ##
============================================
- Coverage 78.50% 78.44% -0.06%
+ Complexity 6752 6750 -2
============================================
Files 759 760 +1
Lines 22402 22416 +14
Branches 4400 4403 +3
============================================
- Hits 17587 17585 -2
- Misses 4109 4123 +14
- Partials 706 708 +2
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
Hi maintainers 👋
This PR adds a new algorithm MaxAlternatingSum to the devutils package,
with documentation and proper formatting.
All checks passed successfully ✔️
Kindly review when you get time.
Thank you! 🙏