array_diff

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
sayantan_os
Forum Newbie
Posts: 1
Joined: Tue Jun 27, 2006 8:38 am

array_diff

Post by sayantan_os »

hi ppl ...... i have been trying to use two arrays of sizes around 150 elements each .......... now when i compare the 2 using array_diff some elements present in both the arrays get displayed as unique .............. the arrays are of single dimension ........... is there a size constraint ??? SOS !!!
User avatar
aerodromoi
Forum Contributor
Posts: 230
Joined: Sun May 07, 2006 5:21 am

Re: array_diff

Post by aerodromoi »

sayantan_os wrote:hi ppl ...... i have been trying to use two arrays of sizes around 150 elements each .......... now when i compare the 2 using array_diff some elements present in both the arrays get displayed as unique .............. the arrays are of single dimension ........... is there a size constraint ??? SOS !!!
Have you considered that array_diff uses a strict comparison operator?

aerodromoi
User avatar
RobertGonzalez
Site Administrator
Posts: 14293
Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA

Post by RobertGonzalez »

Lots of good information on array_diff can be found on the array_diff page of the PHP Manual.
Post Reply