Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <cmath>
- #include <iostream>
- #include <algorithm>
- using namespace std;
- int main(){
- // ввод
- int n;
- cin >> n;
- int **a = new int*[n];
- for (int i = 0; i < n; i++){
- a[i] = new int[n];
- for (int j = 0; j < n; j++){
- cin >> a[i][j];
- }
- }
- // тело программы
- // вывод массива
- for (int i = 0; i < n; i++){
- for (int j = 0; j < n ; j++){
- cout << a[i][j] << ' ';
- }
- cout << endl;
- }
- system("pause");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement