Skip to content
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

perf: 1.c faster implementation of the leetcode TwoSum problem #902

Open
wants to merge 20 commits into
base: master
Choose a base branch
from

Conversation

straight-into-the-wall
Copy link
Contributor

@straight-into-the-wall straight-into-the-wall commented Oct 25, 2021

Description of Change

A faster and more documented solution of the TwoSum problem on leetcode.

see TwoSum problem on leetcode

Old SubmissionDetail (pdf)

New SubmissionDetail (pdf)

References

Hacktoberfest issue

Checklist

  • Added description of change
  • Added tests and example, test must pass
  • Relevant documentation/comments is changed or added
  • PR title follows semantic commit guidelines
  • Search previous suggestions before making a new one, as yours may be a duplicate.
  • I acknowledge that all my contributions will be made under the project's license.

Notes: faster and more documented solution of the leetcode TwoSum problem

@straight-into-the-wall
Copy link
Contributor Author

I'm expecting this to fail until the #898 will not be solved. For this I proposed two alternative solution in #900 and #901.

@Panquesito7 Panquesito7 added the enhancement New feature or request label Oct 25, 2021
@Panquesito7
Copy link
Member

Let's wait until #901 is merged. Feel free to ping me in case I forgot about this PR. 🙂

@straight-into-the-wall
Copy link
Contributor Author

Let's wait until #901 is merged. Feel free to ping me in case I forgot about this PR. slightly_smiling_face

ping.

@straight-into-the-wall
Copy link
Contributor Author

@Panquesito7 ping! This PR is ready too.

leetcode/src/1.c Outdated Show resolved Hide resolved
leetcode/src/1.c Show resolved Hide resolved
leetcode/src/1.c Show resolved Hide resolved
leetcode/src/1.c Outdated Show resolved Hide resolved
Co-authored-by: David Leal <halfpacho@gmail.com>
Copy link
Member

@Panquesito7 Panquesito7 left a comment

Choose a reason for hiding this comment

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

Got this error while trying to compile.

image

Could you please fix the error? Let us know if you need any help. 🙂

@straight-into-the-wall
Copy link
Contributor Author

Hi @Panquesito7. Thanks for your time.

This should fix ... if I remember well as it didn't reproduce on my env.
Knowing what compilation parameters are used to check will help.

Co-authored-by: David Leal <halfpacho@gmail.com>
leetcode/src/1.c Outdated Show resolved Hide resolved
Co-authored-by: David Leal <halfpacho@gmail.com>
Copy link
Member

@Panquesito7 Panquesito7 left a comment

Choose a reason for hiding this comment

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

LGTM 🚀 Thank you for your contribution! 😄👍

@Panquesito7 Panquesito7 added the approved Approved; waiting for merge label Dec 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Approved; waiting for merge enhancement New feature or request
2 participants