Sep 5, 2004 #1 JTan Technical User Oct 9, 2001 73 SG Hi, may I know whether foreach loop exists for ksh? If it doesn't, may I know what other shells would have foreach loop? TIA....
Hi, may I know whether foreach loop exists for ksh? If it doesn't, may I know what other shells would have foreach loop? TIA....
Sep 6, 2004 #2 Mike042 MIS May 17, 2004 456 US Hi JTan, There three basic loop constructs in Korn shell scripting: 1) for loops eg: for <variable> in <word> [<word> ... ] do <commands> done 2) while loops eg: while <command> do <commands> done 3) until loops eg: until <command> do <commands> done But try the man pages (man ksh) on the flavour of UNIX you are using for further details. For the other shells, see their man pages. I hope that helps. Mike Upvote 0 Downvote
Hi JTan, There three basic loop constructs in Korn shell scripting: 1) for loops eg: for <variable> in <word> [<word> ... ] do <commands> done 2) while loops eg: while <command> do <commands> done 3) until loops eg: until <command> do <commands> done But try the man pages (man ksh) on the flavour of UNIX you are using for further details. For the other shells, see their man pages. I hope that helps. Mike