PrepAway - Latest Free Exam Questions & Answers

How can you put every sub-string into an array element easily?

You have a variable $test that contains sub-strings divided by a dash (“-“). How can you put every
sub-string into an array element easily?

PrepAway - Latest Free Exam Questions & Answers

A.
extract($test, “-“);

B.
explode(“-“, $test);

C.
to_array($test, “-“);

D.
explode($test, “-“);

One Comment on “How can you put every sub-string into an array element easily?


Leave a Reply

Your email address will not be published. Required fields are marked *