Why is this microtime showing up weird in PHP

后端 未结 4 1515
栀梦
栀梦 2021-01-17 23:52

Why is this microtime showing up weird in PHP

$start4 = microtime(true);
    // run some php code
$end4 = microtime(true);
print \"Time4: \". ($end4 - $start         


        
4条回答
  •  梦毁少年i
    2021-01-18 00:04

    Dont forget float:

    number_format( (float) microtime(true), 10 );
    ------------------^
    

    update: appended to top answer.

提交回复
热议问题