On Thu, May 15, 2014 at 11:24 PM, Ozgur Akgun <ozgurak...@gmail.com> wrote:
> Hi,
>
> Is it possible in GNU Parallel to have argument ranges depend on earlier
> argument values? For example, how would one translate the following nested
> for loop to use GNU Parallel?
>
> for i in {1..3}; do
>     for j in $(seq 1 $i); do
>         echo $i $j
>     done
> done

You cannot have the inner variables depend on the outer, but you can
ignore values like this:

parallel  '[ {1} -ge {2} ] && echo {1} {2}' ::: {1..3} ::: {1..3}


/Ole

Reply via email to