EmbLogic's Blog

what is meaning of “i+1″ in pf statment

#include
#define MONTHS 12
int main()
{
int days[MONTHS]={31,28,[4]=31,30,31,[1]=29};
int i;
for(i=0;i<MONTHS;i++)
printf("%2d %d\n",i+1,days[i]);
return 0;
}

One Response to what is meaning of “i+1″ in pf statment

  1. Sumit says:

    The valve of i added by 1 and printed….

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>