An open API service indexing awesome lists of open source software.

https://github.com/mxssl/leetcodetwosumgolang


https://github.com/mxssl/leetcodetwosumgolang

Last synced: over 1 year ago
JSON representation

Awesome Lists containing this project

README

          

# LeetCodeTwoSumGolang

Given an array of integers, return indices of the two numbers such that they add up to a specific target.

You may assume that each input would have exactly one solution, and you may not use the same element twice.

```
go test ./... -v -cover
=== RUN TestCase
Expected: [0 1], Output: [0 1]
--- PASS: TestCase (0.00s)
PASS
coverage: 76.9% of statements
ok github.com/mxssl/LeetCodeTwoSumGolang 0.153s coverage: 76.9% of statements
```