I want to take out words that reoccur in array1 and put them in array3.
(so in array 3 there would be only distinct values)
the problem is.. i dont understand how the count2 value can reach so high. (over 300) but should be 20 maximum.
for(i=0; i<count;i++){
if(count2==0){
//put the first value in array3
strcpy(array3[0], array1[0]);
count2++;
}
else{
for(j=0;j<count2;j++){
//if they are same
if(strncmp(array1[i], array3[j], 3)==0){
}
else{
//different
strcpy(array3[count2], array1[i]);
count2=count2+1;
}
}
}
}