[Tutor] foreach loops

Christopher Spears cspears2002 at yahoo.com
Tue Sep 12 05:32:34 CEST 2006


Hmmm...Perl is probably a bad example.  My apologies. 
I was thinking more along the lines of this:

A C++ for loop:

#include <iostream>

using std::cout;

int main() {
	
	for (int i = 0; i < 10; i++) {
		cout << i << "\n";
	}
	
	return 0; 
}




More information about the Tutor mailing list