What will this very short PHP code print out?

This is actually the line of code:

$coll = array(“fruit”)=>”pear”, “car”=.”ford”);
foreach($coll since i) indicate “$i by “;

the answer really should be One of these…..

ONE.pear back button ford x
ONLY TWO.fruit by car x
THREE.Array (fruit => pear by car=>ford x)
SEVERAL.fruit is pear by car is ford x

Cheers

The rule has 2 errors meaning that the result might be parse malfunction.

Problem 1.”…array(“fruit”)=>…”, the parenthesis right after fruit can’t be now there, the ending parenthesis ought to be after the array make.I assume this is a typo.

Problem 2.”car”=.”ford” The time after your equals should not be right now there.The period is used if you want to join strings but it should often be utilised int the form “str1”.”str2″ and also $str.= “….”.Take away it.Again I assume this is a typo.

While using error corrected the end result will be number one “pear back button ford x”.

Leave a Reply