Hi I am a newbie to JuMP(Julia) and coding too,

I am currently computing the following constraints in code below however, it is returning the following error and I am not exactly sure how to solve and I do not understand the error at all. Some of the other constraints have been computed using similar syntax and are returning no errors. Is there something I am missing?

MethodError: no method matching isless(::Int64, ::Array{UnitRange{Int64},1})

Closest candidates are:

isless(!Matched::Missing, ::Any) at missing.jl:87

isless(!Matched::FlexTable{1}, ::AbstractArray{T,1} where T) at C:\Users\glmab.julia\packages\TypedTables\ZF2b3\src\FlexTable.jl:308

isless(::Real, !Matched::AbstractFloat) at operators.jl:166

β¦

Stacktrace:

[1] <(::Int64, ::Array{UnitRange{Int64},1}) at .\operators.jl:277

[2] <=(::Int64, ::Array{UnitRange{Int64},1}) at .\operators.jl:326

[3] macro expansion at C:\Users\glmab.julia\packages\MutableArithmetics\bPWR4\src\rewrite.jl:276 [inlined]

[4] macro expansion at C:\Users\glmab.julia\packages\JuMP\qhoVb\src\macros.jl:440 [inlined]

[5] (::var"#430#435")(::String) at C:\Users\glmab.julia\packages\JuMP\qhoVb\src\Containers\macro.jl:183

[6] #28 at C:\Users\glmab.julia\packages\JuMP\qhoVb\src\Containers\container.jl:85 [inlined]

[7] iterate at .\generator.jl:47 [inlined]

[8] collect(::Base.Generator{JuMP.Containers.VectorizedProductIterator{Tuple{Array{String,1}}},JuMP.Containers.var"#28#29"{var"#430#435"}}) at .\array.jl:686

[9] map(::Function, ::JuMP.Containers.VectorizedProductIterator{Tuple{Array{String,1}}}) at .\abstractarray.jl:2188

[10] container(::Function, ::JuMP.Containers.VectorizedProductIterator{Tuple{Array{String,1}}}, ::Type{JuMP.Containers.DenseAxisArray}) at C:\Users\glmab.julia\packages\JuMP\qhoVb\src\Containers\container.jl:85

[11] container(::Function, ::JuMP.Containers.VectorizedProductIterator{Tuple{Array{String,1}}}) at C:\Users\glmab.julia\packages\JuMP\qhoVb\src\Containers\container.jl:65

[12] top-level scope at C:\Users\glmab.julia\packages\JuMP\qhoVb\src\macros.jl:91

[13] top-level scope at In[54]:9

[14] include_string(::Function, ::Module, ::String, ::String) at .\loading.jl:1091

```
@constraints example2_netprofit begin
tight1[j in j],
sum(sum( (alpha[i]*w[i,n,np] + beta[i]*bs[i,n,np] ) for n in 1:length(n) if n <= np <= n+d) for i in Ij1) <= H
tight2[j in j],
sum(sum( (alpha[i]*w[i,n,np] + beta[i]*bs[i,n,np] ) for n in 1:length(n) if n <= np <= n+d) for i in Ij2) <= H
tight3[j in j],
sum(sum( (alpha[i]*w[i,n,np] + beta[i]*bs[i,n,np] ) for n in 1:length(n) if n <= np <= n+d) for i in Ij3) <= H
tight4[j in j],
sum(sum( (alpha[i]*w[i,n,np] + beta[i]*bs[i,n,np] ) for n in 1:length(n) if n <= np <= n+d) for i in Ij4) <= H
tight5[j in j],
sum(sum( (alpha[i]*w[i,n,np] + beta[i]*bs[i,n,np] ) for n in 1:length(n) if n <= np <= n+d) for i in Ij5) <= H
end
```