#include<iostream> using std::cout; int main() { int tal; tal = 1; while (tal <= 100) { cout << tal << "\n"; tal+=1; } cout << "Slut!"; return 0; }
#include<iostream> using std::cout; int main() { for (int tal=1; tal <= 100; tal++) { cout << tal << "\n"; } cout << "Slut!"; return 0; }
Källa: http://blinkenlights.se/