Skip to content

Renamed method variables #7296

Draft
CasualProgrammer25 wants to merge 4 commits intoTheAlgorithms:masterfrom
CasualProgrammer25:master
Draft

Renamed method variables #7296
CasualProgrammer25 wants to merge 4 commits intoTheAlgorithms:masterfrom
CasualProgrammer25:master

Conversation

@CasualProgrammer25
Copy link

@CasualProgrammer25 CasualProgrammer25 commented Mar 1, 2026

  1. Renamed method variables for improved readability in the sort method of InsertionSort. Previous names for the "startingIndex" and "endingIndex" parameters were obscure. Also renamed parameter "array" to "elements" for better readability.

  2. Renamed method name "findMaxIndex" to "toFindIndexOfMax" in Pancakesort class.

  3. Renamed array "aux" to "tempArray in the MergeSort class for better readability.

  • Updated JavaDoc
  • 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 algorithms include a corresponding test class that validates their functionality.
  • All new code is formatted with clang-format -i --style=file path/to/your/file.java

@codecov-commenter
Copy link

codecov-commenter commented Mar 1, 2026

Codecov Report

❌ Patch coverage is 93.75000% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 79.42%. Comparing base (8b41533) to head (105d642).

Files with missing lines Patch % Lines
...in/java/com/thealgorithms/sorts/InsertionSort.java 87.50% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff            @@
##             master    #7296   +/-   ##
=========================================
  Coverage     79.41%   79.42%           
- Complexity     7060     7062    +2     
=========================================
  Files           788      788           
  Lines         23129    23129           
  Branches       4548     4548           
=========================================
+ Hits          18369    18371    +2     
  Misses         4024     4024           
+ Partials        736      734    -2     

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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