programming-examples/perl/Statement/You can use a for loop to loop for a specific number of times.pl

11 lines
152 B
Perl
Raw Normal View History

2019-11-15 12:59:38 +01:00
#for (initialization; expression; continue) {
# # ...
#}
#!/usr/bin/perl -w
for ($i = 0; $i < 10; $i++) {
print "Iteration $i.\n";
}