// Program to print V alphabet in C with C Bhasha Gyan
#include<stdio.h>
int main()
{
int i, j, k;
for (i=1; i<=5; i++)
{
for(k=1; k<=i; k++)
printf (" "); // allow single space
for(j=i; j<=5; j++)
{
if( j==i || j==5) // for 1st and last position
printf(" *"); // single space and star
else
printf(" "); // allow double space
}
printf("\n");
}
return 0;
}
Output:
* *
* *
* *
* *
*
⏪ Program to Print Alphabet U Program to Print Alphabet W⏩
#include<stdio.h>
int main()
{
int i, j, k;
for (i=1; i<=5; i++)
{
for(k=1; k<=i; k++)
printf (" "); // allow single space
for(j=i; j<=5; j++)
{
if( j==i || j==5) // for 1st and last position
printf(" *"); // single space and star
else
printf(" "); // allow double space
}
printf("\n");
}
return 0;
}
Output:
* *
* *
* *
* *
*
Practical demonstration in Pictorial form-
Program to print V alphabet in C Language without Graphics |
Output:
Program to print V alphabet in C Language without Graphics Output |
⏪ Program to Print Alphabet U Program to Print Alphabet W⏩
No comments:
Post a Comment