# How to properly use Structs in Julia?

**URL:** <https://discourse.julialang.org/t/how-to-properly-use-structs-in-julia/58465>\
**Category:** General Usage\
**Tags:** question\
**Created:** [April 2, 2021, 9:17pm UTC](https://discourse.julialang.org/t/how-to-properly-use-structs-in-julia/58465 "2021-04-02T21:17:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Renan\_Rabelo](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/renan_rabelo/32/8048_2.png) [@Renan\_Rabelo](https://discourse.julialang.org/u/Renan_Rabelo)\
**Post date:** [April 2, 2021, 9:17pm UTC](https://discourse.julialang.org/t/how-to-properly-use-structs-in-julia/58465/1 "2021-04-02T21:17:27Z")

</div>

Hi,

I’m using Julia about 6 months by now and I never understood Structs well.

Before Julia I used to code in Processing, and OOP in Julia seems so different that I don’t even know how methods and objects work and how to write them.

I tried to read the [documentation](https://docs.julialang.org/en/v1/manual/constructors/) but couldn’t make sense of anything! (those types and functions declarations seems too messy for me)

Can anyone make a concise and short explanation of how Structs work?

Thanks!

---

<div class="post-metadata">

**Author:** ![lmiq](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/lmiq/32/18314_2.png) [@lmiq](https://discourse.julialang.org/u/lmiq)\
**Post date:** [April 2, 2021, 9:24pm UTC](https://discourse.julialang.org/t/how-to-properly-use-structs-in-julia/58465/2 "2021-04-02T21:24:01Z")

</div>

Take a look at this thread. If you are used to OOP, it may help: [Is Julia's way of OOP superior to C++/Python? Why Julia doesn't use class-based OOP? - #10 by lmiq](https://discourse.julialang.org/t/is-julias-way-of-oop-superior-to-c-python-why-julia-doesnt-use-class-based-oop/52058/10)

(I linked directly my answer there because, while very basic relatively to the depth of the discussion, may be a more direct answer to your question)

---

<div class="post-metadata">

**Author:** ![Renan\_Rabelo](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/renan_rabelo/32/8048_2.png) [@Renan\_Rabelo](https://discourse.julialang.org/u/Renan_Rabelo)\
**Post date:** [April 2, 2021, 9:42pm UTC](https://discourse.julialang.org/t/how-to-properly-use-structs-in-julia/58465/3 "2021-04-02T21:42:26Z")

</div>

Your explanation is very good!

Thanks!
