ad

Thursday, June 6, 2024

php loop to print alphabet pattern V


php  loop  to print alphabet pattern V


php  loop  to print alphabet pattern V

Example :-

<?php
echo "<pre>";
//loop for row
for($row=0;$row<7; $row++){
    //loop for column
    for($col=0;$col<=7;$col++)
    {
        //condition determine print echo '*'
value
       if((($col==1 or $col==5) and $row <5)or
       ($row==6 and $col==3)or ($row==5 and
($col==2 or $col ==4)))  
        echo "*";
                //print condition met
           
           else
            echo "&nbsp;";
        //if condition
           }          
    echo "<br>"; }

echo "</pre>";
?>

php  loop  to print alphabet pattern V

output :-

php  loop  to print alphabet pattern V


Related Post :-

php string operators

css text decoration

inline css in html

Wednesday, June 5, 2024

php loop to print alphabet pattern T


php  loop  to print alphabet pattern T

php  loop  to print alphabet pattern T 













Example :- 


<?php
echo "<pre>";
//loop for row
for($row=0;$row<6; $row++){
    //loop for column
    for($col=0;$col<=7;$col++)
    {
        //condition determine print echo '*'
value
        if($col==3 or ($row==0 and $col>0 and
$col<6))    
                 echo "*";
                //print condition met
           
           else
            echo "&nbsp;";
        //if condition
           }
         
   
    echo "<br>"; }

echo "</pre>";
?>



php  loop  to print alphabet pattern 



Output :-

php program to print alphabet pattern D

   
php program to print alphabet pattern D













php program to print alphabet pattern D




Example :-



<?php
//loop for rows
echo "<pre>";
for($row=0;$row<11; $row++){
//loop for column
    for($col=0;$col<=11;$col++)
    {
//condition to determine print echo '*'
        if($col==1 or (($row==0 or $row==10 )and
        ($col>1 and $col<9)) or ($col==9
and $row !=0 and $row !=10))
        {
                 echo "*";
           }
           else {
            echo "&nbsp;";
           }
    }  
    echo "<br>";
}
echo "</pre>";
?>


php program to print alphabet pattern D

Output :-

php program to print alphabet pattern D


Related Post :- 

php program factorial number program

reset passwored form

Sunday, June 2, 2024

php program to print Alphabet pattern s

 

php program to print Alphabet pattern s

php program to print Alphabet pattern s

Example :-

<?php

for($row=0; $row<7; $row++)
{
       for ($column=0; $column<=7; $column++)
    {
       if((($row==0 or $row==3 or $row==6)
       and $column>1 and $column <5) or
($column==1
    and ($row==1 or $row==2 or $row==6))or
    ($column==5 and ($row==0 or $row==4 or
$row==5)))
       
       
        echo "*" ;  
        else  
        echo "&nbsp; ";
    }
    echo"<br>";
}
?>

 

php program to print Alphabet pattern s

Output :-

php program to print Alphabet pattern s

Related Post :-

javascript arithmetic operators

forgot password form

php program print square number pattern

php program to print Alphabet pattern y

 

php program to print Alphabet pattern y

php program to print Alphabet pattern y

Example :-

<?php

for($row=0; $row<7; $row++)
{
       for ($column=0; $column<=7; $column++)
    {
       if((($column==1 or $column==5)and $row<2)
or
       $row==$column and $column>0 and $column
<4 or($column==4
       and $row ==2 )or (($column==3)and $row>3))
        echo "*";
    else
    echo "&nbsp; ";
    }
    echo "<br>";
}
?>

php program to print Alphabet pattern y

Output :-

php program to print Alphabet pattern y


Related Post :-

javascript email validation

javascript while loop

php program to print hourglass star pattern