Saturday, March 29, 2008

While.....do.....done

This is one of my most frequently use iteration statement when I want to poll something and view something.

Let me give you a stupid example:

[root@panda ~]# while true; do date; sleep 5; done
Sat Mar 29 18:36:06 PDT 2008
Sat Mar 29 18:36:11 PDT 2008


No comments: