PHP list+explode VS substr+strpos - what is more efficient?

后端 未结 6 1713
迷失自我
迷失自我 2021-01-04 22:24

Sample text:

$text = \'Administration\\Controller\\UserController::Save\';

Task - extract everything before ::

Option 1:

         


        
6条回答
  •  刺人心
    刺人心 (楼主)
    2021-01-04 22:56

    efficient ? if you mean by execution time. then run each in a loop multiple (1000) time and check the execution time.

提交回复
热议问题