Print Star Pattern Triangle using loop is a C program. It prints a right angle triangle of stars as following:
*
**
***
*****
******
/*Write a C Program to print the following Star Pattern * ** *** **** ***** */ #include <stdio.h> int main() { int row, col; for(row=1;row<=5;row++) { for(col=1;col<=row;col++) { printf("*"); } printf("\n"); } return 0; }
This image shows a sample run and output of the c program to show a star triangle as required: