tibberous Posted August 31, 2007 Share Posted August 31, 2007 I need to find all the elements that are in one array and not the other. I was able to do this with a foreach loop and the in_array function, but I was wondering if there isn't a more efficient way, since right now it is comparing an array of several thousand items to another array of several thousand items. Thanks Quote Link to comment https://forums.phpfreaks.com/topic/67399-solved-finding-elements-that-are-in-one-array-that-are-not-in-another/ Share on other sites More sharing options...
tibberous Posted August 31, 2007 Author Share Posted August 31, 2007 array_diff No one ever answers my posts =( Quote Link to comment https://forums.phpfreaks.com/topic/67399-solved-finding-elements-that-are-in-one-array-that-are-not-in-another/#findComment-338379 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.