The following code is from Armstrong's Erlang textbook:
pythag(N) -> [ {A,B,C} || A <- lists:seq(1,N), B <- lists:seq(1,N), C <- lists:seq(1,N), A + B + C =< N, A * A + B * B =:= C * C ]. When calling pythag (N), erlang uses 100% of only one core out of 4 available, with the obvious possibility of parallelization (especially necessary when N> 100). So it should be? How to make this example processed in parallel?