diff options
| author | Paul Buetow <pbuetow@mimecast.com> | 2020-08-08 16:24:56 +0100 |
|---|---|---|
| committer | Paul Buetow <pbuetow@mimecast.com> | 2020-08-08 16:24:56 +0100 |
| commit | 9bee249738c6bbea23a3618bd487d8d046dd2fc4 (patch) | |
| tree | 2189d706a25d18d69411964b55a3a6b938120709 /ds/arraylist.go | |
| parent | d5a41348086fd357f8f74ec55cf38d6236bf5366 (diff) | |
fix test
Diffstat (limited to 'ds/arraylist.go')
| -rw-r--r-- | ds/arraylist.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ds/arraylist.go b/ds/arraylist.go index 8e99384..e0e4536 100644 --- a/ds/arraylist.go +++ b/ds/arraylist.go @@ -8,6 +8,10 @@ import ( type ArrayList []int +func NewArrayList(l int) ArrayList { + return make(ArrayList, l) +} + func NewRandomArrayList(l, max int) ArrayList { a := make(ArrayList, l) for i := 0; i < l; i++ { |
