main()

{

char c;

int i = 456;

clrscr();

c = i;

printf("%d", c);

}

a. 456

b. -456

c. random number

d. none of the above

Answers were Sorted based on User's Feedback



main() { char c; int i = 456; clrscr(); c = i; printf("%d"..

Answer / guest

d) -56

Is This Answer Correct ?    23 Yes 5 No

main() { char c; int i = 456; clrscr(); c = i; printf("%d"..

Answer / satya

ans: -56
explanation:
it mainly focus on integer range
it will prints the output like this
for 1=1
2=2....127=-127,
128=-128,
129=-127....256=0;
similarly
456 means 256+256=512=0;
456-512=-56

Is This Answer Correct ?    10 Yes 2 No

main() { char c; int i = 456; clrscr(); c = i; printf("%d"..

Answer / karthi

d.none of the above

Is This Answer Correct ?    8 Yes 2 No

Post New Answer

More C Code Interview Questions

write the function. if all the character in string B appear in string A, return true, otherwise return false.

11 Answers   Google,


#include<stdio.h> main() { FILE *ptr; char i; ptr=fopen("zzz.c","r"); while((i=fgetch(ptr))!=EOF) printf("%c",i); }

1 Answers  


main() { 41printf("%p",main); }8

1 Answers  


Write a C program to print look and say sequence? For example if u get the input as 1 then the sequence is 11 21 1211 111221 312211 12112221 .......(it counts the no. of 1s,2s etc which is in successive order) and this sequence is used in run-length encoding.

1 Answers  


main() { extern i; printf("%d\n",i); { int i=20; printf("%d\n",i); } }

1 Answers  


write a c program to Reverse a given string using string function and also without string function

1 Answers  


What is data _null_? ,Explain with code when u need to use it in data step programming ?

0 Answers   Abbott,


void main() { int i=5; printf("%d",i++ + ++i); }

3 Answers  


main( ) { void *vp; char ch = ‘g’, *cp = “goofy”; int j = 20; vp = &ch; printf(“%c”, *(char *)vp); vp = &j; printf(“%d”,*(int *)vp); vp = cp; printf(“%s”,(char *)vp + 3); }

1 Answers  


Write a c program to search an element in an array using recursion

1 Answers   Wipro,


given integer number,write a program that displays the number as follows: First line :all digits second line : all except the first digit . . . . Last line : the last digit

8 Answers  


main() { int i; i = abc(); printf("%d",i); } abc() { _AX = 1000; }

2 Answers  


Categories