Home > Article > Backend Development > Looking for an optimized version of this algorithm! ! ! !
problems encountered in the project. There are several small arrays in a large array, but the small arrays may be repeated, and the interface needs to return a non-duplicate array structure. I tried the built-in function array_merge() in PHP, but it cannot sort small arrays. Here's how I use it. I can only say that the efficiency is very low. If you see this article and have a good method, please tell me. :) //$hotel_setting may contain repeated large arrays. The small array structure is array('hotel_adt_cnt'=>'','hotel_chd_cnt'=>'');
|