In a sense, you have already reviewed your own code. You have weighed the pros and cons of various approaches, and even challenged yourself to consider how to transpose the output. It's no surprise that your question has been well received on Code Review.
Be careful to look at the big picture. None of these solutions is bad code, even if some of these solutions are better than others. Even when we say that something is "inefficient", it's just an matter of craftsmanship rather than a real performance issue, because any computation will be dwarfed by the I/O and program initialization overhead.
The most idiomatic way to do something n times in C/C++ is
for (int i = 0; i < n; i++) {
…
}
It can also be done with for (int i = 1; i <= n; i++), but only if you have a good reason to start at 1. A third way is while (n--) { … }, if you don't need to preserve the original value of n and don't need to count upwards. Any other loop structure, such as
for(int row=0; row<=(maxrows-1); row++)
… would be unconventional and likely to lead to off-by-one errors.
It's best to avoid recomputing invariants such as maxrows * maxcols in the loop condition.
I'm not a fan of the first two approaches.
The first approach has pos initialized on one line, tested on a second line, and incremented in a third place. That makes it hard to follow.
The second approach tries to perform a two-dimensional task using one linear loop. I have some mild concerns about computing maxrows*maxcols and (pos%maxcols)==0 every time you print a number. You also left the declarations int row; int col; for unused variables there; compiling with warnings enabled should have warned you about that.
The third approach, with two nested for-loops, is the most straightforward way to make a grid. However, the implementation is marred by the unconventional loop counting, as mentioned above.
I think that the most elegant solution would be to decouple the grid-counting loops from the content-generating calculation:
int n = 0;
for (int row = 0; row < maxrows; row++) {
for (int col = 0; col < maxcols; col++) {
std::cout << std::setw(7) << (n += multiple);
}
std::cout << "\n";
}
You can also use that technique to produce a transposed table, though it's less elegant.
int stride = maxrows * multiple;
for (int row = 1; row <= maxrows; row++) {
for (int col = 1, n = row * multiple; col <= maxcols; col++, n += stride) {
std::cout << std::setw(7) << n;
}
std::cout << "\n";
}