Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- for (int j = 0; j < n3_j; j++) {
- for (int i = 0; i < n3_j; i++){
- v1 = input_array[0][j];
- v2 = input_array[1][i];
- int rnd = dist(mt);
- switch (rnd) {
- case 0: {
- res = v1 + v2;
- break;
- }
- case 1: {
- res = v1 - v2;
- break;
- }
- case 2: {
- res = v1 * v2;
- break;
- }
- default: {
- res = v1 / v2;
- }
- }
- res_array[0][rc] = v1;
- res_array[1][rc] = v2;
- res_array[2][rc] = rnd;
- res_array[3][rc] = res;
- rc++;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement