changed from map to integer array