Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 27 Oct 2001 09:51:28 +0300
From:      Odhiambo Washington <wash@wananchi.com>
To:        FreeBSD user <freebsd@XtremeDev.com>
Cc:        FBSD-Q <freebsd-questions@freebsd.org>
Subject:   Re: Newbie-Simple C Shell programming help
Message-ID:  <20011027095128.C80546@ns2.wananchi.com>
In-Reply-To: <20011026134417.O35370-100000@Amber.XtremeDev.com>
References:  <20011026193434.45814.qmail@web9607.mail.yahoo.com> <20011026134417.O35370-100000@Amber.XtremeDev.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--wac7ysb48OaltWcw
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

* FreeBSD user <freebsd@XtremeDev.com> [20011026 22:46]: writing on the sub=
ject 'Re: Newbie-Simple C Shell programming help'
| #!/bin/sh
| N=3D1
| while [ $N -le 100 ]
| do
|   echo $N
|   N=3D`expr $N+1`


N=3D`expr $N + 1`

The spaces before and after the (+) - that is one thing I read about quite
recently while trying to get the picture about shell scripting....



| done
|=20
| And /bin/sh is not a c shell.
|=20
|=20
| On Fri, 26 Oct 2001, The Almonds wrote:
|=20
| > All,
| >
| > I am trying to run a program via a c shell 100 times
| > for a stress test.
| >
| > I have
| > #!/bin/sh
| > for 1 in 1 2 3
| >
| > do
| >
| > x
| >
| > done
| >
| > as you can see this is painful if I want to do 100.
| > Anyone know of a quick way to do this for 100 loops.
| >
| > Curtis
| >
| > __________________________________________________
| > Do You Yahoo!?
| > Make a great connection at Yahoo! Personals.
| > http://personals.yahoo.com
| >
| > To Unsubscribe: send mail to majordomo@FreeBSD.org
| > with "unsubscribe freebsd-questions" in the body of the message
| >
| >
| >
|=20
|=20
| To Unsubscribe: send mail to majordomo@FreeBSD.org
| with "unsubscribe freebsd-questions" in the body of the message

-Wash

S y s t e m s   A d m i n i s t r a t o r
--
                                              ~\\_                =20
 Odhiambo Washington                            \\\\              =20
 Wananchi Online Ltd.,                          `\\\\\            =20
 1st Flr Loita Hse, Loita Street                 |\\\\\           =20
 PO Box 10286,00100-NAIROBI,KE.                   \\\\\|__.--~~\  =20
 Fax: 254 2 313985-9                           _--~            /  =20
 Fax: 254 2 313922                           /~ //////  _-~~~~'   =20
 E-mail: wash@wananchi.com                  ('-//////-//          =20
 URL	: http://www.wananchi.com            //////(((-)          =20
 GSM: 254 72 743 223 / 254 733 744 121     /////"                 =20
                                        _///"                     =20

+++
Self Test for Paranoia:
	You know you have it when you can't think of anything that's
your own fault.

--wac7ysb48OaltWcw
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (FreeBSD)
Comment: For info see http://www.gnupg.org

iD8DBQE72llwn7LIsuxjem8RAoO1AJoDYFgFX0qUasabLv8qjh9nst6GpACfXCo5
702vOtFDp3mD/KrIcrB0uro=
=I6vW
-----END PGP SIGNATURE-----

--wac7ysb48OaltWcw--

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011027095128.C80546>