# ZeroJudge - a015: 矩陣的翻轉 ### 題目連結:https://zerojudge.tw/ShowProblem?problemid=a015 ###### tags: `ZeroJudge` `陣列` ```cpp= #include <iostream> using namespace std; int main() { cin.sync_with_stdio(false); cin.tie(nullptr); int matrix[100][100], rows, columns; while (cin >> rows >> columns) { for (int i = 0; i < rows; ++i) for (int j = 0; j < columns; ++j) cin >> matrix[i][j]; for (int j = 0; j < columns; ++j) { for (int i = 0; i < rows; ++i) cout << matrix[i][j] << ' '; cout << '\n'; } } } ```