Red Hat Linux is irrelavent here.
A "For Loop" is a feature of many popular programming languages, it usually can be one of two flavors depending on the language:
The first style has an initializer, a test to see if it should keep going, and a place to increment the counting variable. From the C language:
Code:
// this example counts from 1 to 10
int i;
for (i = 1; i <= 10; i = i + 1) {
printf("%d\n", i);
}
In other languages, the for loop iterates over values in a list. For example in the Python language:
Code:
values = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
for value in values:
print value
The bash shell (this is probably what you meant by "Red Hat Linux") also uses this style of for loop:
Code:
# list files in current directory
for file in *
do
echo "$file"
done