标签:style blog io color sp on div log cti
直接上代码
<?php class example{ public static $pa; public $pb; public function __construct(){ $this->pb = ++self::$pa; } } $a = new example; $b = new example; echo $a->pb; echo ‘<hr/>‘; echo $b->pb; ?>
本来想结果应该是
1 ----------------------------------------------------- 1
可是我错了,正确的结果是
1 ---------------------------------------------------------------------------------- 2
基础没学好,赶快补补
标签:style blog io color sp on div log cti
原文地址:http://www.cnblogs.com/uduemc/p/4122271.html