From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12916 invoked from network); 3 Feb 1998 19:33:01 -0000 Received: from math.gatech.edu (list@130.207.146.50) by ns1.primenet.com.au with SMTP; 3 Feb 1998 19:33:01 -0000 Received: (from list@localhost) by math.gatech.edu (8.8.5/8.8.5) id OAA09856; Tue, 3 Feb 1998 14:07:36 -0500 (EST) Resent-Date: Tue, 3 Feb 1998 14:06:40 -0500 (EST) Message-ID: <19980203140851.04316@astaroth.nit.gwu.edu> Date: Tue, 3 Feb 1998 14:08:51 -0500 From: Sweth Chandramouli To: ZSH Users Subject: cross-product array function? Mail-Followup-To: ZSH Users Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.89 Resent-Message-ID: <"zR7A83.0.DO2._gsrq"@math> Resent-From: zsh-users@math.gatech.edu X-Mailing-List: archive/latest/1308 X-Loop: zsh-users@math.gatech.edu X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu is there a function in zsh to take two arrays/lists, and create a new one that is their cross-product? in es (extensible shell), i could do foo="first second third"; bar="word person base"; echo foo^bar; and the output would be the following list: "firstword secondword thirdword firstperson secondperson thirdperson firstbase secondbase thirdbase" is there some similar function in zsh? tia, sweth. -- "Countin' on a remedy I've counted on before Goin' with a cure that's never failed me What you call the disease I call the remedy" -- The Mighty Mighty Bosstones