Question:Which of the following is correct way to use curly brace in the string?
A $capicals=array("bangladesh"=>"Dhaka"); echo "This capital of Bangladesh is {$capitals["bangladesh"]}";
B $capicals=array("bangladesh"=>"Dhaka"); echo "This capital of Bangladesh is {{$capitals["bangladesh"]}}";
C $capicals=array("bangladesh"=>"Dhaka"); echo "This capital of Bangladesh is {$capitals['bangladesh']}";
D $capicals=array("bangladesh"=>"Dhaka"); echo "This capital of Bangladesh is {$capitals[bangladesh]}";
+ Answer ModeratedC
+ Report