Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<iostream>
- using namespace std;
- const int length = 20;
- void arr1Line(int arr[][length], int n)
- {
- for (int i = 0; i < n; i++)
- {
- for (int j = 0; j < n; j++)
- {
- cout<<arr[i][j]<<' ';
- }
- }
- }
- int main() {
- int arr[length][length];
- int n;
- do
- {
- cin >> n;
- } while (n<=0||n>length);
- arr1Line(arr, n);
- system("pause");
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement