Switch branches/tags
Nothing to show
Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
..
Failed to load latest commit information.
README.md
missingnumbers.go
missingnumbers_test.go

README.md

Missing Numbers

Given an array containing all the numbers from 1 to n except two, find the two missing numbers.

Example

  • missing([]int{4, 2, 3}) = []int{1, 5}
  • missing([]int{1, 2, 3, 4}) = []int{5, 6}

Run tests with benchmarks

go test -bench .