Skip to content

Instantly share code, notes, and snippets.

@austa
Created March 10, 2013 22:07
Show Gist options
  • Save austa/5130717 to your computer and use it in GitHub Desktop.
Save austa/5130717 to your computer and use it in GitHub Desktop.
/*
* File: main.c
* Author: alaattin
*
* Created on 10 Mart 2013 Pazar, 22:11
*/
#include <stdio.h>
#include <stdlib.h>
/*
*
*/
int main(int argc, char** argv) {
int i = 0, j = 0, taban = 0;
printf("Taban uzunlugunu giriniz ");
scanf("%d",&taban);
for(i=0;i < taban; i++){
for(j=0;j <= i; j++){
printf("*");
}
printf("\n");
}
for(i=taban-1;i > 0 ; i-- ){
for(j=0;j<i;j++){
printf("*");
}
printf("\n");
}
return (EXIT_SUCCESS);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment