C Program
C program to Print Alphabet F star pattern
Example :-
#include <stdio.h>
int main() {
int a, b;
int rows = 7;
for (a = 0; a < rows; a++) {
for (b = 0; b < rows; b++) {
if (a == 0)
printf("*");
else if (a == rows / 2 && b < rows - 2)
printf("*");
else if (b == 0)
printf("*");
else
printf(" ");
}
printf("\n");
}
return 0;
}
No comments:
Post a Comment