#include <stdio.h>

int main() {
	int input;

	printf("Enter an integer: ");
	scanf("%d", &input);

	for (int row = 1; row <= input; row++) {
		for (int col = 0; col < input - row; col++) {
			printf(" ");
		}

		for (int col = 1; col <= row * 2 - 1; col++) {
			printf("*");
		}

		printf("\n");
	}
}
⇪