R
Raistlin
Hey, for c++ does any body have a way to compare two arrays? Say one
has the numbers 1-5000, the other has *most* of the numbers from
1-5000, is there a way to display the numbers that are in the 1st
array, but not in the 2nd array? Or load those numbers in a 3rd array?
Thats the simple version...there are a couple other problems: ex:
the 10th value of the 2nd array corresponds to the 12th value of the
first.
- you cant simply make a for loop and compare each individual one...
The arrays are different sizes...one having 5000 values, the other
like 4700ish.
Any ideas? I was thinking of something like writing the smaller array
into a file, and then having something read the values of the first
array, and if it doesnt find it in the file, then it sends it to a
diff file or something...but I have NO IDEA how to code that...
Any ideas/thoughts/etc would be very welcome =)
has the numbers 1-5000, the other has *most* of the numbers from
1-5000, is there a way to display the numbers that are in the 1st
array, but not in the 2nd array? Or load those numbers in a 3rd array?
Thats the simple version...there are a couple other problems: ex:
the 10th value of the 2nd array corresponds to the 12th value of the
first.
- you cant simply make a for loop and compare each individual one...
The arrays are different sizes...one having 5000 values, the other
like 4700ish.
Any ideas? I was thinking of something like writing the smaller array
into a file, and then having something read the values of the first
array, and if it doesnt find it in the file, then it sends it to a
diff file or something...but I have NO IDEA how to code that...
Any ideas/thoughts/etc would be very welcome =)