Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <iomanip>
- using std::cin;
- using std::cout;
- using std::endl;
- using std::setw;
- int main() {
- int i, j, n=10, base_num(1);
- for (i=0; i < n; i++) {
- base_num += 2;
- for (j=0; j<=i; j++) {
- cout << setw(4) << base_num + j;
- }
- cout << endl;
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement