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

Added isogram utility class and unit tests #6594

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
alxkm merged 19 commits into TheAlgorithms:master from JeevaRamanathan:jeeva/isogram
Oct 3, 2025

Conversation

Copy link
Contributor

@JeevaRamanathan JeevaRamanathan commented Oct 2, 2025

This PR implements isogram detection in Java to determine whether a word contains each letter exactly once, using two methods and added unit tests.
isIsogramByArray() – Uses a boolean array for constant space validation.
isIsogramByLength() – Uses a HashSet to compare unique character count.

  • 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

Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Copy link

codecov-commenter commented Oct 2, 2025
edited
Loading

Codecov Report

❌ Patch coverage is 95.45455% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 75.70%. Comparing base (8d14b49) to head (624e880).

Files with missing lines Patch % Lines
...c/main/java/com/thealgorithms/strings/Isogram.java 95.45% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@ Coverage Diff @@
## master #6594 +/- ##
============================================
+ Coverage 75.66% 75.70% +0.03% 
- Complexity 5742 5755 +13 
============================================
 Files 698 699 +1 
 Lines 19703 19725 +22 
 Branches 3820 3826 +6 
============================================
+ Hits 14909 14933 +24 
+ Misses 4215 4214 -1 
+ Partials 579 578 -1 

☔ 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.

JeevaRamanathan and others added 15 commits October 2, 2025 22:16
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Signed-off-by: JeevaRamanathan <jeevaramanathan.m@infosys.com>
Copy link
Member

@alxkm alxkm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Thanks for the contribution.

JeevaRamanathan reacted with heart emoji
@alxkm alxkm merged commit 7e29be3 into TheAlgorithms:master Oct 3, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers

@alxkm alxkm alxkm approved these changes

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

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

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

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