Skip to content
Snippets Groups Projects
Commit cdbd9f68 authored by Mohamed Yasar arafath K M's avatar Mohamed Yasar arafath K M :speech_balloon:
Browse files

intial commit

parent a1a843bb
No related branches found
No related tags found
No related merge requests found
pascal.c 0 → 100644
#include<stdio.h>
#include<stdlib.h>
int main(int argc, char const *argv[])
{
int i,j,space,n,row=atoi(argv[1]);
for (i = 0; i < row; i++)
{
for ( space = 0; space < row-i; space++)
{
printf(" ");
}
for ( j = 0; j < 2*i-1; j++)
{
if (j==0)
{
n=1;
}
else
{
n = n*(i-j+1)/j;
}
printf("%d ",n);
}
printf("\n");
}
return 0;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment