
samantha grace
New User
Dec 24, 2008, 4:09 AM
Post #1 of 2
(338 views)
|
|
2D array:print rows whose first element matches.
|
Can't Post
|
|
hi, i have a situation where i need to find and print all the rows in a two dimensional array whose first element matches. my 2d array looks like this: [name1,10,function_name1] [name1,16,function_name2] [name2,5,function_name3] [name2,44,function_name1] [name3,32,function_name4] [name4,24,function_name5] the output should be something like this: [name1,10,function_name1] [name1,16,function_name2] [name2,5,function_name3] [name2,44,function_name1] i.e all rows with repeated first element i.e with the same name. any help is welcome!! thanks, Sam
|