#include using namespace std; const int MAX_N = 100; const int MAX_M = 100; int n, m, x; int a[MAX_N][MAX_M]; int main() { cin >> n >> m >> x; for (int i = 0; i < n; ++i) for (int j = 0; j < m; ++j) cin >> a[i][j]; for (int i = 0; i < n * x; ++i) { for (int j = 0; j < m * x; ++j) { cout << a[i / x][j / x] << " "; } cout << "\n"; } }