The article is quite old. Try randbool() instead of randbit(). Best to 
remove such an old reference from the website.

-viral

On Monday, November 24, 2014 8:37:59 AM UTC+5:30, Airhead Bit wrote:
>
> Everything in a language I need but the examples at 
> http://julialang.org/learning/ like 
>
> Parallel Julia by Douglas Eadline in Admin magazine
> Just blow up:
>  tic();
>
> julia> nheads = @parallel (+) for i=1:100000000
>              randbit()
>              end;
> exception on 2: exception on 5: exception on exception on 3: 4: ERROR: 
> randbit not defined
>  in anonymous at no file:2
>  in anonymous at multi.jl:1279
>  in anonymous at multi.jl:848
>  in run_work_thunk at multi.jl:621
>  in run_work_thunk at multi.jl:630
>  in anonymous at task.jl:6
> ERROR: randbit not defined
>  in anonymous at no file:2
>  in anonymous at multi.jl:1279
>  in anonymous at multi.jl:848
>  in run_work_thunk at multi.jl:621
>  in run_work_thunk at multi.jl:630
>  in anonymous at task.jl:6
> ERROR: randbit not defined
>  in anonymous at no file:2
>  in anonymous at multi.jl:1279
>  in anonymous at multi.jl:848
>  in run_work_thunk at multi.jl:621
>  in run_work_thunk at multi.jl:630
>  in anonymous at task.jl:6
> ERROR: randbit not defined
>  in anonymous at no file:2
>  in anonymous at multi.jl:1279
>  in anonymous at multi.jl:848
>  in run_work_thunk at multi.jl:621
>  in run_work_thunk at multi.jl:630
>  in anonymous at task.jl:6
> ERROR: `+` has no method matching +(::UndefVarError, ::UndefVarError)
>  in _mapreduce at reduce.jl:166
>  in mapreduce at reduce.jl:182
>  in preduce at multi.jl:1418
>
> julia> s=toc();
> elapsed time: 1.6460936 seconds
>
> julia> println("Number of Heads: $nheads in $s seconds")
> ERROR: nheads not defined
>
> and
> julia> addprocs_local(1)
> dies
> but addprocs(1) works (after hunting it down with Google.
>
> Please fix or remove broken examples, I've used up my time fighting 
> something that should not have happened, trying examples of deprecated code.
>
>
>

Reply via email to