Use Filter In Array Of Pointers In Cpp