# BoundsError

**URL:** <https://discourse.julialang.org/t/boundserror/53961>\
**Category:** Data\
**Tags:** error\
**Created:** [January 26, 2021, 9:34am UTC](https://discourse.julialang.org/t/boundserror/53961 "2021-01-26T09:34:16Z")\
**Posts on this page:** 1\
**Showing post:** 2

<div class="post-metadata">

**Author:** ![Henrique\_Becker](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/henrique_becker/32/15443_2.png) [@Henrique\_Becker](https://discourse.julialang.org/u/Henrique_Becker)\
**Post date:** [January 26, 2021, 1:02pm UTC](https://discourse.julialang.org/t/boundserror/53961/2 "2021-01-26T13:02:11Z")

</div>

Hi @ashwanimalviya, welcome to our community! 🎊

I recommend you look at our [list of good practices](https://discourse.julialang.org/t/psa-make-it-easier-to-help-you/14757). I think you used the blockquote instead of triple backticks to post your code and it lost its identation, making it harder to read. If you use triple backticks instead the spacing is preserved (and a monospace font is used).

If you break your code in smaller functions the error message will probably be more precise. For now it is hard to understand which exact line of your problem that is throwing the error.

Giving your code a look, I found strange that you have `M, N = size[DAG]`, did you mean `M, N = size(DAG)`? Do you have some data to test you function with that throws the same error?

---

_[View the full topic](https://discourse.julialang.org/t/boundserror/53961)._
