It appears that (!$a == 'hello') is consistently faster than ($a != 'hello')
// (!$a == 'hello')
Used time: 52.743232011795
Used time: 52.633831977844
Used time: 51.452646970749
//($a != 'hello')
Used time: 76.290767908096
Used time: 81.887389183044
Used time: 64.569777011871
Any idea why this is happening? I understand that this level of optimization is irrelavent in most of the cases. The question is purely out of curiosity. (Ref: http://www.php.net/manual/en/language.operators.comparison.php#99216)