WILL COMPARISON OF STRING "10" AND INTEGER 11 WORK IN PHP?

Awadhendra Tiwari

Total Post:505

Points:2525
Posted by  Awadhendra Tiwari
PHP 
PHP
 2588  View(s)
Ratings:
Rate this:
  1. Awadhendra Tiwari

    Post:505

    Points:2525
    Will comparison of string "10" and integer 11 work in PHP?

    Yes, internally PHP will cast everything to the integer type, so numbers 10 and 11 will be compared.

Answer

NEWSLETTER

Enter your email address here always to be updated. We promise not to spam!