# Fastest way of getting a long zero vector?

**URL:** <https://discourse.julialang.org/t/fastest-way-of-getting-a-long-zero-vector/111628>\
**Category:** General Usage\
**Created:** [March 14, 2024, 5:56pm UTC](https://discourse.julialang.org/t/fastest-way-of-getting-a-long-zero-vector/111628 "2024-03-14T17:56:26Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![stevengj](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/stevengj/32/71_2.png) [@stevengj](https://discourse.julialang.org/u/stevengj)\
**Post date:** [March 14, 2024, 6:01pm UTC](https://discourse.julialang.org/t/fastest-way-of-getting-a-long-zero-vector/111628/2 "2024-03-14T18:01:45Z")

</div>

> [@PetrKryslUCSD](#):
>
> Is there something faster?

You could use `calloc`. See e.g. [Faster zeros with calloc](https://discourse.julialang.org/t/faster-zeros-with-calloc/69860) and ArrayAllocators.jl

---

_[View the full topic](https://discourse.julialang.org/t/fastest-way-of-getting-a-long-zero-vector/111628)._
