predict o/p

#define PrintInt(expr) printf("%s:%d\n",#expr,(expr))
int main()
{
/* The powers of 10 */
int pot[] = {
0001,
0010,
0100,
1000
};
int i;

for(i=0;i<4;i++)
PrintInt(pot[i]);
return 0;
}

Comments

  1. please post this answer i wanna kno :(

    ReplyDelete
  2. pot[i] : 1
    pot[i] : 8
    pot[i] : 64
    pot[i] : 1000
    for description of this solution please visit this post
    http://code-forum.blogspot.com/2010/11/c-puzzles.html

    ReplyDelete

Post a Comment

Popular posts from this blog