Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "stdafx.h"
- #include <iostream>
- int main()
- {
- int b = 2;
- double result;
- for (int e = 1; e < 10; e++)
- {
- result = pow(b, e);
- std::cout << result << "\n"; // prints result to console and a new line
- }
- std::cout << "Press Enter to continue";
- std::getchar(); // wait for enter to be pressed
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement