Home Modern › Forums › ISRO › What is the output of the following ‘c’ code assuming it runs on a byte addressed little endian machine? (A) 622 What is the output of the following ‘c’ code assuming it runs on a byte addressed little endian machine? (A) 622#include <stdio.h>
int
main( )
{
int
x;
char
*ptr;
x = 622,100,101;
printf
(
"%d"
, (*(
char
*)&x) * (x % 3));
return
0;
}
(B) 311
(C) 22
(D) 110#include <stdio.h>
int
main( )
{
int
x;
char
*ptr;
x = 622,100,101;
printf
(
"%d"
, (*(
char
*)&x) * (x % 3));
return
0;
}
(B) 311
(C) 22
(D) 110
nan