php判断表达式中false在==前后的区别?

WBOY
Release: 2016-06-23 14:15:39
Original
1054 people have browsed it

false在==前后的区别


回复讨论(解决方案)

没有区别,习惯而已

没有区别,习惯而已
有人这样说:这个是为了解决逻辑判断错误的写法,如果false置前,但只写一个=号的情况下,不会出现语句错误!

正相反!如果写作 false = $a 会产生 Parse error: syntax error, unexpected '=' in 错误
而 $a = false 就不会

自己对自己就那么没信心?

嗯 我说反了。

source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!