Linux Today: Linux News On Internet Time.
Search Linux Today
search.internet.com
Linux News Sections:  Blog -  Developer -  High Performance -  Infrastructure -  IT Management -  Security -  Storage -
Linux Today Navigation
LT Home
Preferences
Contribute
Link to Us
Search
Linux Jobs

Become a Marketplace Partner

internet.commerce
Be a Commerce Partner














The Linux Channel at internet.com
Linux Today
Enterprise Linux Today
Apache Today
JustLinux.com
Linux Planet
PHPBuilder
All Linux Devices
Technology Jobs

JustTechJobs.com

LinuxToday Newsletters
Subscribe News
Subscribe PR
Subscribe Security

internet.com
IT
Developer
Internet News
Small Business
Personal Technology

Search internet.com
Advertise
Corporate Info
Newsletters
Tech Jobs
E-mail Offers

 






Current Newswire:

Hands-on: OpenMoko WikiReader is simple, appealing

Perl far from dead, more popular than you think

Microsoft Exchange alternatives

Kubuntu 9.10: A Mixed Bag

Could Microsoft switch to Linux?

Red Hat Virtualization Manager for Windows Only?

Creating Ebooks with Sigil

Editor's Note: Making Multi-Channel Firewire Music With Linux

Amaya: A Simple, Yet Useful Alternative to Dreamweaver

Windows 7 Sales Up, But is it Really a Hit?




UNIX System Administrator - SUN Solaris, Veritas, EMC, Shell Scripting, SAN (NYC)
Next Step Systems
US-NY-New York

Justtechjobs.com Post A Job | Post A Resume
:Bash Tricks I: (very) Repetitive tasks
Bash Tricks I: (very) Repetitive tasks
Feb 18, 2009, 09 :04 UTC (0 Talkback[s]) (4275 reads)

(Other stories by Edmundo Carmona)

[ Thanks to Edmundo Carmona for this link. ]

"Repetitive tasks
Sometimes, you might want to repeat a task a number of times. For example, right now I want to find out which one is faster on PHP: Using variables or defining constants

"I have two script where I define a constant/variable (depending on the script) and I write its value to stdout. Let's say I want to run the variable.php script 1000 times. What I do is:

"i=0; while [ $i -lt 1000 ]; do php variable.php > /dev/null; i=$(( $i + 1 )); done

"But what does all that stuff mean? Let's decompose it:"

Complete Story

Related Stories:
Organizing Files by File Type (Feb 14, 2009)
A few Linux terminal commands to spice it up(Feb 12, 2009)
Colorful man pages in linux(Feb 11, 2009)
Wicked Cool Ruby Scripts(Feb 06, 2009)
How to be Faster at the Linux Command Line(Feb 04, 2009)
Chaining Linux Commands Together(Feb 03, 2009)
Take a hard look at the command line(Feb 02, 2009)



No talkbacks posted.
  Home | Search Talkbacks | Customize View    Top of Page  



Enter your comments below:

* Your Name:

* Your Email Address:

* Subject:

CC: [will also send this talkback to an E-Mail address]

* Comments:

Tags allowed:<I>,<B> and <U>. See our talkback-policy for more about talkback content.

Fields marked with * are required!






..............................




All times are recorded in UTC.
Linux is a trademark of Linus Torvalds.
Powered by Linux, Apache and PHP

internet.commediabistro.comJusttechjobs.comGraphics.com

Search:

WebMediaBrands Corporate Info

Legal Notices, Licensing, Reprints, Permissions, Privacy Policy.
Advertise | Newsletters | Shopping | E-mail Offers | Freelance Jobs