…also you’ve got a spurious : in else: on line 77.
On Wednesday, June 18, 2014 4:59:34 PM UTC-7, Ethan Anderes wrote: I also noticed that when D is an array, statements like D(k,i) = d should > be written D[k,i] = d instead. > > On Wednesday, June 18, 2014 4:40:11 PM UTC-7, shashank shekhar wrote: > > Hi >> >> I have written an algorithm for the K Center problem in 1 dimensional >> using dp. Here : >> https://github.com/shkr/Algorithms/blob/master/KCenter1D.jl >> >> But upon including the file >> >> *julia> **include("KCenter1D.jl")* >> >> *ERROR: syntax: malformed function arguments 1* >> >> * in include at boot.jl:238* >> >> * in include_from_node1 at loading.jl:114* >> >> *at /Users/shashankshekhar/git/Algorithms/KCenter1D.jl:35* >> >> >> *line 35 : *B = ones(Float64,(K,N)) >> >> >> *Help in solving this error will be appreciated. I just started writing >> in julia today.* >> >> >> *Thanks* >> >> >> >> >
