changed some arrays to pointers.\n added mininum int for the index