Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <time.h>
- int main()
- {
- setlocale(LC_ALL, "Rus");
- const int n = 100;
- int Matrix[n][n];
- for (int i = 0; i < n; i++)
- {
- std::cout << std::endl;
- for (int j = 0; j < n; j++)
- {
- if (i == j)
- Matrix[i][j] = 1;
- else
- if (i > j)
- Matrix[i][j] = 0;
- else
- Matrix[i][j] = i + j;
- std::cout << Matrix[i][j] << "\t";
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment