C programme to print "B" or "8"

 #include<stdio.h>

int main()

{

    int i,j;

    for (i=1; i<=5; i++)

    {

        for(j=1; j<=4;j++)

        {

        if(i==1 || j==1 || i==3 || j==4 ||i==5)

        {

            printf("*");   

        }

        else

        {

            printf(" ");

        }

        }

         printf("\n");

    }

        return 0;

    

}

Comments

Popular posts from this blog

C Programme to find Area Of Rectangle

C programme to reverse the number