Skip to main content

Blank Bottle C language Code

Blank Bottle C language Code


#include<stdio.h>
void main()
{
   int i,j,k;

   for(i=1;i<=1;i++)
    {
        printf("     ");
    for(j=1;j<=5;j++)
    {
        printf("*");
    }
    }
   for(i=1;i<=5;i++)
   {
       printf("     ");
       for(j=1;j<=1;j++)
       {
           printf("*");
       }
       printf("     ");
       for(j=1;j<=1;j++)
       {
           printf("*");
       }
       printf("\n");
    }
    k=4;
    for(i=1;i<=5;i++)
    {

        for(j=1;j<=6-i;j++)
        {
            if(j<=k)
                printf(" ");
            else
                printf("*");
        }
         k--;

        printf("     ");
        for(j=1;j<=i+i-1;j++)
        {
                printf(" ");
        }
        for(j=1;j<=1;j++)
        {
            printf("*");
        }


        printf("\n");


    }

    for(i=1;i<=10;i++)
    {
        for(j=1;j<1;j++)
            printf("     ");
        {
            printf("*");
        }
        printf("          ");

        for(j=15;j<16;j++)
            printf("     ");
        {
            printf("*");
        }
        printf("     ");

        printf("\n");
    }
    for(i=1;i<=1;i++)
    {
    for(j=1;j<=17;j++)
    {
        printf("*");
    }
    }



}

Comments

Popular posts from this blog

Prime Number C language Code | Niks banna

Prime Number C language Code  C language code runs on some text editiors who compile it and run it. here is the code copy it all paste on your .c extension file #include<stdio.h> void main() {     int i,n,t=0; scanf("%d",&n); for(i=2;i<n;i++) {     if(n%i==0)     {         printf("not a prime number");         t=1;         break;     } }     if(t==0)     {         printf("Prime number");     } } THANKS FOR READING FOLLOW ME  

Find Maximum Value C language Code

Find Maximum Value C language Code #include <stdio.h> int main() {   int array[100], maximum, size, c, location = 1;   printf("Enter the number of elements in array\n");   scanf("%d", &size);   printf("Enter %d integers\n", size);   for (c = 0; c < size; c++)     scanf("%d", &array[c]);   maximum = array[0];   for (c = 1; c < size; c++)   {     if (array[c] > maximum)     {        maximum  = array[c];        location = c+1;     }   }   printf("Maximum element is present at location %d and it's value is %d.\n", location, maximum);   return 0; } THANKS FOR READING  FOLLOW ME