Last active
August 6, 2021 11:39
-
-
Save percybolmer/1a2a75f99f5c0d62e22f5736f20f56e1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// BenchmarkInsertIntMap100000 benchmarks the speed of inserting 100000 integers into the map. | |
func BenchmarkInsertIntMap100000(b *testing.B) { | |
for i := 0; i < b.N; i++ { | |
insertXIntMap(100000, b) | |
} | |
} | |
// BenchmarkInsertIntMap10000 benchmarks the speed of inserting 10000 integers into the map. | |
func BenchmarkInsertIntMap10000(b *testing.B) { | |
for i := 0; i < b.N; i++ { | |
insertXIntMap(10000, b) | |
} | |
} | |
// BenchmarkInsertIntMap1000 benchmarks the speed of inserting 1000 integers into the map. | |
func BenchmarkInsertIntMap1000(b *testing.B) { | |
for i := 0; i < b.N; i++ { | |
insertXIntMap(1000, b) | |
} | |
} | |
// BenchmarkInsertIntMap100 benchmarks the speed of inserting 100 integers into the map. | |
func BenchmarkInsertIntMap100(b *testing.B) { | |
for i := 0; i < b.N; i++ { | |
insertXIntMap(100, b) | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment