Programa:       Unidad2Ejercicio14.cpp
Descripción:    Suma los mil primeros números naturales
#include <iostream>
using namespace std;
void main ()
        int i, suma = 0;

        for(i = 1; i <= 1000; i++)
                suma += i;

        cout << "La suma de los numeros 1...1000 = " << suma;


Ad blocker interference detected!

Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.