PHP · Question 12 of 12

Which statements about conditions in PHP are correct?

3 answers are correct. Hard

Show answer

Answer

  • B if checks a condition and runs code depending on the result
  • D switch compares a value with several case branches
  • E match compares strictly and returns a value

Explanation

In additional.php, if or match select values per application context, for example. match compares with ===, switch with ==, and only switch knows falling through without break.

Certifications & exams

Which exam comes next?

You can already practise for 19 exams, and 21 are up for a vote. See all certifications with their official information, cast your vote or suggest your exam.

See all certifications