+ 2
<?php $sum =0 ; for(i=0;i<=30;i++) { if(i%9==0) $sum=$sum+i; } echo"\n sum is \n ",$sum; ?>
Solve this problem 🤔😡 https://code.sololearn.com/wQTCMvUWtSAF/?ref=app https://code.sololearn.com/wQTCMvUWtSAF/?ref=app
3 odpowiedzi
+ 4
Try now you forget $ in loop
<?php
$sum =0;
for($i=0;$i<30;$i++)
{
if($i%9==0)
$sum+=$sum+$i;
}
echo("sum is =$sum");
?>
+ 4
Jeeshan Momin welcome sir
+ 2
Thanks alot🎉😅