Advertisement
Guest User

ejercicio while

a guest
Sep 18th, 2014
194
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.21 KB | None | 0 0
  1. //Gerardo Morales
  2. //Imprime del 0 al 5
  3. #include <iostream>
  4. using namespace std;
  5. int num;
  6. int main()
  7. {
  8. while (num <= 5)
  9. {
  10. cout<<num<<endl;
  11. num++; //Es lo mismo num=num+1
  12. }
  13. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement