i get a warning messages while doing merge between two sorted arrays into one sorted array as follows: and the error or warning messages that come to me are: C6385 & C6201
#include <iostream>
using namespace std;
int main()
{
int arr1[5] = { 1,3,5,7,9 }, arr2[5] = { 0,2,4,6,8 }, arr3[10];
for (int i = 1; i <= 9; i++)
if (arr1[i] < arr2[i])
arr3[i] = arr1[i];
else
arr3[i] = arr2[i];
cout << arr3[10] << endl;
return 0;
}
Aucun commentaire:
Enregistrer un commentaire