A double for loop requires a comma between the variables
julia> for i=1:10, j=1:10
println(i," , ",j)
end
To get you're desired result a single loop is sufficient.
julia> for i=1:10
println(i," , ",i)
end
1 , 1
2 , 2
3 , 3
4 , 4
5 , 5
6 , 6
7 , 7
8 , 8
9 , 9
10 , 10
Den tisdag 27 januari 2015 kl. 11:35:12 UTC+1 skrev paul analyst:
>
> What wrong
> julia> for i=1:10 j=1:10;
> println(i," , ",j)
> end
> 1 , 1:10
> 2 , 1:10
> 3 , 1:10
> 4 , 1:10
> 5 , 1:10
> 6 , 1:10
> 7 , 1:10
> 8 , 1:10
> 9 , 1:10
> 10 , 1:10
>
>
> I need result :
>
> 1 , 1
> 2 , 2
> 3 , 3
> 4 , 4
> 5 , 5
> 6 , 6
> 7 , 7
> 8 , 8
> 9 , 9
> 10 , 10
>
> Paul
>