I have been developing a code that executes a function using an array and now the problem started to happen when I put that function in a loop…I get the message saying that the array is not defined… I wrote the word global but it did not help
Did anyone encounter this message or error before and what was the solution ?
This type of super-obscure communication will only be understood by those who are both very familiar with programming discussion fora and Sherlock Holmes (if I’m interpreting you correctly). It doesn’t appear very welcoming.
Don’t worry about what was written, but look at the link (it’s this one Please read: make it easier to help you). It will help you write your question in a way that makes it easier to answer.
this is what allows you to e.g. define an Array{Float64}(undef, 5). Change the name or your array to array (lowercase) or my_array or whatever suits you.
As an aside, stylistic convention in Julia is that capitalized identifiers (such as Array, Float64, Int etc) are used for types, while variables / instances of a type have lowercase names.