What is the output of the following problem ?

			  		

Loading

Practice Arrays – What is the output of the following problem ?


int main()
{
char s[ ]="man";
int i;
for(i=0;s[ i ];i++)
printf("
%c%c%c%c",s[ i ],*(s+i),*(i+s),i[s]);
return 0;
}

What is the output of the following problem ?

			  		

Loading

Practice Functions – What is the output of the following problem ?


#include

int main() {
int factorial(int n);
int i,ans;
ans = factorial(5);
printf("
Factorial by recursion = %d
", ans);
return 0;
}
int factorial(int n)
{
if (n <= 1)
return (1);
else
return ( n * factorial(n-1));
}

What is the output of the following problem ?

			  		

Loading

Practice Structures, Unions, Enums – What is the output of the following problem ?


#include

struct {
int x;
int y;
union {
int id_no;
char *name;
}b;
}s,*st;
int main()
{
st = &s;
st->x=10;
st->b.id_no = 101;
printf("%d %d
",s.x,s.b.id_no);
return 0;
}

What is the output of the following problem ?

			  		

Loading

Practice Control Instructions – What is the output of the following problem ?


#include
int main()
{
int i;
for (i=9;i<13; i++)
printf("%d %0x ",i,i);
return 0;
}

What is the output of the following problem ?

			  		

Loading

Practice Arrays – What is the output of the following problem ?


#include
int main()
{
func(1);
return 0;
}
func(int i){
static char *str[] = {"One","Two", "Three", "Four"};
printf("%s
",str[i++]);
return;
}

What is the output of the following problem ?

			  		

Loading

Practice Strings – What is the output of the following problem ?


#include
int main()
{
int len=4;
char *st="12345678";
st = st + len;
printf("%c
",*st);
return 0;
}