Я столкнулся с моим следующим препятствием в каком-то коде, который я пытаюсь отладить и проработать.
ERROR: LoadError: MethodError: no method matching Array(::Type{Int64}, ::Int64)
Closest candidates are:
Array(::LinearAlgebra.UniformScaling, ::Integer, ::Integer) at C:\cygwin\home\Administrator\buildbot\worker\package_win64\build\usr\share\julia\stdlib\v1.1\LinearAlgebra\src\uniformscaling.jl:345
Я просмотрел предоставленный материал, и похоже, что определения массивов, возможно, изменились на использование arr
или Array{Int64,0}
... но, похоже, они мне тоже не помогли.Любой совет?Заранее спасибо!
# Puts the output of one lineup into a format that will be used later
if status==:Optimal
data_lineup_copy = Array(Int64, 0)
for i=1:num_data
if getValue(data_lineup[i]) >= 0.9 && getValue(data_lineup[i]) <= 1.1
data_lineup_copy = vcat(data_lineup_copy, fill(1,1))
else
data_lineup_copy = vcat(data_lineup_copy, fill(0,1))
end
end
for i=1:num_shot
if getValue(shot_lineup[i]) >= 0.9 && getValue(shot_lineup[i]) <= 1.1
data_lineup_copy = vcat(data_lineup_copy, fill(1,1))
else
data_lineup_copy = vcat(data_lineup_copy, fill(0,1))
end
end
return(data_lineup_copy)
end
end
data1 = Array(Int64, 0)
data2 = Array(Int64, 0)
data3 = Array(Int64, 0)