What is the wrong with this code

<?php
$languages =array(‘te’,‘hi’);
for($langIndex = 0; $langIndex<count($languages) ;$langIndex++)
{
echo $languages;
}

actual result is:Array Array

but expected result is:te,hi
is there any wrong with this code

<?php 
$languages =array('te','hi');
for($langIndex = 0; $langIndex<count($languages) ;$langIndex++)
{
echo $languages[$langIndex];
}

And there is no real need to use indexes at all:


<?php 
$languages =array('te','hi');
foreach($languages as $language)
{
echo $language . "\
";
}