Could anyone help me out?
I'm doing a problem that requires a 2 dimensional array, and everything is working fine and storing. However, at the end of the program I get 3 error messages saying the program is crashed even though it executed properly. I'm using Borland c++ 5, here's the code if it'll help out
#include <stdio.h>
#include <iostream.h>
#include <time.h>
#include <stdlib.h>
void main(){
int matrix[4][5];
int rr,cc;
int max=500;
int min=-500;
randomize();
for (rr=1;rr<=4;rr++){
for (cc=1;cc<=5;cc++){
matrix[rr][cc] = (rand() % (max + 1 - min)) + min;
cout <<matrix[rr][cc]<<" ";
}
cout <<"\n";
}
//return(0);
}