Skip to content

Update Pangram.java using Java Collections - #4479

Merged
debasishbsws merged 6 commits into
TheAlgorithms:masterfrom
Ankit-Saha08:patch-4
Oct 1, 2023
Merged

Update Pangram.java using Java Collections#4479
debasishbsws merged 6 commits into
TheAlgorithms:masterfrom
Ankit-Saha08:patch-4

Conversation

@Ankit-Saha08

@Ankit-Saha08 Ankit-Saha08 commented Oct 1, 2023

Copy link
Copy Markdown
Contributor

A simple separate function isPangramOrNot(String s) has been created which implements the Pangram checking of a string using Java Collection Framework approach.

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

A simple separate function isPangramOrNot(String s) has been created which implements the Pangram checking of a string using Java Collection Framework approach.
@Ankit-Saha08

Copy link
Copy Markdown
Contributor Author

I request the maintainer(s) to merge my request using "hacktoberfest-accepted" label.

Comment thread src/main/java/com/thealgorithms/strings/Pangram.java Outdated
Co-authored-by: Debasish Biswas <debasishbsws.dev@gmail.com>
@debasishbsws

debasishbsws commented Oct 1, 2023

Copy link
Copy Markdown
Member

Looks like you haven't add test for your function. (It is always better to add test you know)
https://github.com/TheAlgorithms/Java/blob/master/src/test/java/com/thealgorithms/strings/PangramTest.java
Add some test for you method too. you can use the same example just with your method call.
and isPangramUsingSet(String s) is a better name.

BTW thanks for contributing.

@Ankit-Saha08

Copy link
Copy Markdown
Contributor Author

Ok, I will update the method name isPangramUsingSet(String s) and also add some tests for my method.

Method name updated to - isPangramUsingSet(String s)
@Ankit-Saha08

Copy link
Copy Markdown
Contributor Author

Hi, I have updated the function name to isPangramUsingSet(String s) and also added tests for my function.

P.S. - I would be grateful if my contribution is accepted and merged using "hacktoberfest-accepted" label.

@debasishbsws

Copy link
Copy Markdown
Member

Add the test in this barnch.

Successfully updated the testcases in this same PR branch
@Ankit-Saha08

Copy link
Copy Markdown
Contributor Author

Hii, I have updated the test cases in PangramTest.java file in this current PR branch itself.

P.S. - Looking forward to having my contribution merged and accepted.

@debasishbsws debasishbsws left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks Good. Thanks

@debasishbsws
debasishbsws merged commit ee2629c into TheAlgorithms:master Oct 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants