Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream.h>
- #include <conio.h>
- #include <ctime>
- using namespace std;
- int main(){
- int m,n,i,j,summ,arr[2][2];
- srand(time(NULL));
- for (i=0;i<2;i++){
- for (j=0;j<2;j++){
- for (i=0;i<2;i++){
- m = rand() % 10 + 1;
- n = rand() % 10 + 1;
- }
- arr[i][j] = arr[m][n];
- }
- }
- for (i=0;i<2;i++){
- for (j=0;j<2;j++){
- cout << "[" << arr[i][j] << "]";
- }
- }
- system("pause");
- return(0);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement