Diamond Patterin In C Programming Tamil


/*
	   *
	 *   *
       *   *   *
    *    *   *    *
 *     *    *   *    *
    *     *   *    *
       *    *   *
	 *    *
	    *
*/
#include<stdio.h>
#include<conio.h>
void main()
{
    int i,j,k,n=8;
    clrscr();
    for(i=0;i<n;i++)
    {
       for(j=0;j<n-i;j++)
       {
	  printf(" ");
       }
       for(j=0;j<i;j++)
       {
	 printf(" *");
       }
	printf("\n");
    }
    for(i=0;i<n;i++)
    {
       for(j=0;j<i;j++)
       {
	  printf(" ");
       }
       for(j=0;j<n-i;j++)
       {
	 printf(" *");
       }
	printf("\n");
    }
    getch();
}

Login To Download Source Code

Leave a Comment:

Login To Comment

List Of Programs


Goto Examples

Operators

Looping

Number Conversion

Pattern Design

Arrays

Matrix Examples

Sorting Examples

String Function

Change Case

String In C

Maths Functions

User Defined Functions

Recursive Functions

Pointer

Structure

File Concept

Calender Programming