目录
//代码示例
var_dump("abcdef"[-2]); //string(1) “e”
var_dump(strpos("aabbcc", "b", -3)); //int(3)
var_dump("abcdef"[-60]); //string(0) “”
var_dump(strpos("aabbcc", "b", -5)); //int(2)
//代码示例:
use Namespace\Content\{
Content1,
Content2,
Content3
};
//代码示例:
$x=1;
$y=2;
$fn1=fn($z)=>$x+$z;
$fn3=fn($c)=>fn($d)=>$c*$d*$y;
var_export($fn1(3)); //4
var_export($fn3(4)(5)); //40
//代码示例:
echo “sum: ”.$a+$b;//等同echo “sum: ”.($a+$b); 而不是 echo (“sum: ”.$a)+$b;