Movatterモバイル変換


[0]ホーム

URL:


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: LeetCode solution for Two Sum#523

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Open
sasi-upparapalli wants to merge1 commit intocodedecks-in:master
base:master
Choose a base branch
Loading
fromsasi-upparapalli:add-my-leetcode-solution

Conversation

@sasi-upparapalli
Copy link

Two Sum

Problem:
Given an array of integersnums and an integertarget, return indices of the two numbers such that they add up to target.

Approach:
Use a hash map (dictionary) to store visited numbers and their indices. For each element, check if the complement (target - current number) exists in the map. If yes, return the indices.

Time Complexity: O(n)
Space Complexity: O(n)

Difficulty Level: Easy
Tags: Array, Hash Map

Contributor:sasi-upparapalli

uday1646 reacted with thumbs up emoji
@welcome
Copy link

welcomebot commentedOct 31, 2025

I can tell this is your first pull request! Thank you I'm so honored. 🎉🎉🎉 I'll take a look at it ASAP!

@uday1646
Copy link

Good sasi kanth

@sasi-upparapalli
Copy link
Author

Hello! 👋

This is my first Hacktoberfest contribution, adding a solution for the Two Sum problem with a clear explanation and README update. I would greatly appreciate it if you could take a moment to review this pull request. Please let me know if any improvements or changes are needed.

Thank you very much for your time and for maintaining such a valuable repository!

Best regards,
sasi-upparapalli

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@sasi-upparapalli@uday1646

[8]ページ先頭

©2009-2025 Movatter.jp