Archive for the 'Uncategorized' Category

static variable && recursive main( )

Program to print 1 to n natural numbers using recursion( main( ) ) and static variable !!

#include<stdio.h>
void main( )
{
static int i =1, n;
if(i == 1) scanf(“%d”, &n);
if(i<=n)
{  printf(“%d”, i++);  main( );  }
}

From the Blogger

I will soon make some categories according to the nature of matters that i will post, i.e. Movies, Programming, Songs, Information and some other according to the need.
Name : Abhinav Yadav
Mail ID : abhinavanihba@gmail.com, administrator@abhinavyadav.com
Contact Number : +919871799576
Website : http://www.abhinavyadav.com
Blog : blog.abhinavyadav.com

Hello world!

int main( )
{
printf(“Hello World”);
return 0;
}