From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21514 invoked from network); 12 Sep 1999 23:59:07 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 12 Sep 1999 23:59:07 -0000 Received: (qmail 28003 invoked by alias); 12 Sep 1999 23:58:48 -0000 Mailing-List: contact zsh-users-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 2595 Received: (qmail 27996 invoked from network); 12 Sep 1999 23:58:46 -0000 From: "Bart Schaefer" Message-Id: <990912235140.ZM23741@candle.brasslantern.com> Date: Sun, 12 Sep 1999 23:51:39 +0000 In-Reply-To: Comments: In reply to Gaspar Bakos "evaluating a condition" (Sep 12, 8:41pm) References: X-Mailer: Z-Mail (5.0.0 30July97) To: Gaspar Bakos , zsh-users@sunsite.auc.dk Subject: Re: evaluating a condition MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable On Sep 12, 8:41pm, Gaspar Bakos wrote: } Subject: evaluating a condition } } I have the following script, and I would like to print the numbers in t= he } terminal from ${min} to ${max}, if both of them are smaller than 10. At first I thought you'd found a bug in the math parser, but: } export min=3D$3;export max=3D$4; } if (($[min]<10 &&=A0$[max]<10)) then ^^ There's a metafied space here. I think zsh is interpreting "\240$[max]" = as an identifier; e.g. if max=3D11, the identifier name is "\240\061\061". = That identifier isn't defined, so it's value is 0 which is always < 10. } for i in {${min}..${max}}; do echo $i; done } fi This is a danger of permitting identifiers to contain non-ascii character= s. -- = Bart Schaefer Brass Lantern Enterprises http://www.well.com/user/barts http://www.brasslantern.com