Python
Python copied to clipboard
Add docstring and type hints to two_sum
Description
This pull request adds a detailed docstring and type hints to the two_sum
implementation in the arrays section.
The changes improve code readability and maintainability while keeping the existing algorithm logic unchanged.
Changes Made
- Added a clear docstring explaining the approach
- Added type hints for better clarity
Checklist
- [x] Code follows repository style guidelines
- [x] No functional changes were made